How do you query multiple tables(4 or more) in mysql server using a join.
These tabs in the workbook represents tables in a mySQL database, I am trying to write a query that will return the total invoice charges for the state of Illinois for months January through February and sort it by Customer name I was trying to do a join, how do you go about doing this with a join?
This is what I was thinking
Select C.CustomerName, L.LineAmount
From Customer C Inner Join Invoice I
ON C.CutomerID = I.CustomerID
Inner Join LineItemCharge L
ON I.InvNbr = L.InvLineItemID
Inner Join BillTo b
ON L.InvID = B.InvID
Where I.invdate BETWEEN ‘1/1/2011’ AND ‘2/28/2011’
AND B.BillToState = ‘IL’
ORDER BY CUSTOMER NAME;