Hmm, this looks like it might be the way to go. After running an addapted version of this query, I run into a syntax problem:
#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'case ) as sales1...
Nope, not that easy. I've tried all manner of joins without luck (by this I mean I may get sales figures but they aren't correct) Left Joins, Inner Joins, Right Joins, Prayer Joins etc. nothing correct hehe
I’m trying to join 2 instances of the same table with separate criteria and am running into some serious problems. Essentially, it’s a comparison of an invoice table based on different time criteria. A boiled down version of the table looks like this:
Table name: Invoices
inv_number (int)...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.