|
Posted by Toby Inkster on May 11, 2005, 8:44 am
Please log in for more thread options
> I can do it in normal SQL with a cartesian join but I
> don't know the syntax of the left join. Bannerurls will be missing
> some UIDs that are in banneruser.
The SQL way to LEFT JOIN foo, bar and quux is:
SELECT a,b,c,d
FROM (foo LEFT JOIN bar ON foo.x=bar.y) AS baz LEFT JOIN quux ON
baz.w=quux.z
WHERE b=1
ORDER BY c
LIMIT 5;
Not sure if MySQL supports this. PostgreSQL does. If you're doing a clot
of complex queries, PostgreSQL is what you want.
--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~ http://tobyinkster.co.uk/contact
|