After upgrade from 4.1.22 to 5.1.44 query not working
Posted by:
B B
Date: April 28, 2010 05:24PM
Hi all,
this is my first post here, and I'd like to know whether somebody has experienced problems with query interpretaion after a version change like the one in the subject.
I have multiple left joins like this, which used to work like a charm under version 4 but I get the error "#1054 - Unknown column 'a.email_id' in 'on clause' "
What can I do to make this query work again?
Thanks a lot in advance!
SELECT *
FROM
invoice i,
administration a,
customer c,
product p,
item po
LEFT JOIN
email e
ON
e.email_id = a.email_id
LEFT JOIN
domain d
ON
d.domain_id = a.domain_id
LEFT JOIN
domain d2
ON
d2.domain_id = a.domain2_id
LEFT JOIN
domain d3
ON
d3.domain_id = a.domain3_id
LEFT JOIN
access z
ON
z.access_id = a.access_id
LEFT JOIN
cert z2
ON
z2.cert_id = a.cert_id
WHERE
a.customer_id = 5 AND
i.invoice_id = 235 AND
c.customer_id = a.customer_id AND
p.product_id = a.product_id AND
it.administration_id = a.administration_id AND
it.invoice_id = i.invoice_id
AND
a.administration_id IN (272,278,281,273,276,274,277,280,283)
GROUP BY
a.administration_id
ORDER BY
p.sortorder ASC,
d.domainname ASC,
d2.domainname ASC,
d3.domainname ASC