« first day (1640 days earlier)      last day (1018 days later) » 

5:46 AM
Hello
Need Help
 
 
6 hours later…
11:34 AM
hi
everyone
 
 
3 hours later…
2:53 PM
I am trying to find the total count of each unique county in the state table for the correspoinding state where QA is null

        county table
    | **county column** | |State Code|

     Montgomery              1
     Frederick               2
     Manassas                3


         state table
    | **Date** | |State Code|

     Null             1
     not null         2
     null             3
     not null         2
     null             3

I tried my best with this code, obviously its wrong but I wanted to show a starting query.
any help?
 
 
3 hours later…
5:53 PM
select cou_name, count(*)
from country
inner join state on state.code = country.sd_code
where state.QA_date is null
group by cou_name;
@AlfredH. Not sure if I got the table/column names right but take a look
 
 
3 hours later…
8:38 PM
@Aparna yo
 
user4398985
9:25 PM
Hi Guys
 
Hello
 
user4398985
Does anyone have a good resource to learn Joins?
 
user4398985
I am having tough time understanding joins. Please let me know for any resources. Thanks in advance :)
 
user4398985
hi steve :)
 
9:54 PM
 
user4398985
@Teh
 
user4398985
@TehShrike awesome man :)
 
@ShivaShinde :-)
 
user4398985
thanks!!
 
post here if you have any specific questions
 
user4398985
9:59 PM
SELECT <select list> from TableA A LEFTJOIN TableB B on A.key = B.key
 
user4398985
what does A in "TableA A" is?
 
user4398985
specific column?
 
ah, that's equivalent to saying FROM TableA AS A - it aliases TableA as A
I don't like that syntax, I find it annoying to read, I prefer to put the AS in there to be explicit
 
user4398985
cool :)
 
user4398985
So you will get a "list" which has both Table A and intersection of TableA & TableB
 
10:04 PM
yeah, the left/outer join gets you all rows from A, and all the rows from B that matched the ON clause
 
user4398985
so this list is kind of dynamic right?
 
user4398985
I mean we cant hold it or name it and store it?
 
user4398985
every time we want something like this list.........we have run this query.........am I right?
 
Pretty much. Most database systems let you create a "view" which is a table that you can select from that runs the real query in the background
But yeah, generally to see the data you run the query.
Or, in most cases, you'll load the page that causes the server code to run the query for you and display the results back to you somehow.
 
user4398985
can I do some transactions or calculations based on this query on backend?
 
10:08 PM
@ShivaShinde indeed. If you have multiple queries that depend upon the results of previous queries, you'll probably want to start a database transaction to run them in.
 
FUCK MYSQL ON WINDOWS
 
user4398985
awesome.....thanks @TehShrike
 
FUCK IT ALLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLL!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!‌​!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ALLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLL!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!‌​!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!ALLLLLLLLLLLLLLLLLL
 
user4398985
this day sep 02, 2015 I claim that I know SQL :)
 
@DonLarynx :-P
@DonLarynx is it that bad?
 
10:11 PM
I HAVE WASTED 1:30 ENTIRE HOURS TRYING TO INSTALL SQL ON THIS PIECE OF SHIT
I WILL PUNCH YOU REDMOND SOFTWARE DEVELOER
 
user4398985
he he :)
 
user4398985
windows...is windows
 
user4398985
linux rocks :)
 
fuck windows i'd rather suck a dick
 
@DonLarynx I've run MySQL on plenty of Windows boxes and it wasn't any worse than on Linux
 
10:19 PM
heavens
i've done it
 

« first day (1640 days earlier)      last day (1018 days later) »