Forum Moderators: open
but this returns this error "Unknown column 'customers.cstId' in 'on clause'"
SELECT * FROM customers FULL JOIN tickets ON tickets.cstId = customers.cstId
I've been using left joins for quite a while, but this is the first time i've had to use a full join. i thought it would be just as straight forward.
how come the first two queries return different numbers of records. however #3 and #1 match?
1) SELECT * FROM customers LEFT JOIN tickets ON customers.cstId = tickets.cstId
2) SELECT * FROM customers LEFT JOIN (SELECT * FROM tickets) AS tickets ON customers.cstId = tickets.cstId
3) SELECT * FROM customers LEFT JOIN (SELECT * FROM tickets WHERE 1) AS tickets ON customers.cstId = tickets.cstId