>Hi, > > I have a small problem with a SQL statement. Hi Kevin I forgot to ask what brand of SQL you're using. E.g.: the CASE statement won't work, AFAIK, in MySQL. Although there are a few functions you could try if this is sort of approach is necessary. UNION will only work in MySQL 4.0.0 or later. Cheers Andrew -- Andrew Forsberg --- uberNET - http://uber.net.nz/ the pander - http://thepander.co.nz/