James <ja...@icionline.ca> wrote: > This will only display products which have items with images.
True. Make it select name, filename from products p left join images im on im.item_id = ( select im2.item_id from items left join images im2 on (items.id = im2.item_id) where items.product_id = p.id and items.buyable order by position desc limit 1) order by name; Igor Tandetnik _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users