Hi
I have two tables.
items (item_id, item_name )
images (image_id, item_id, filename, caption, display_order)
What I want is to return a data set containing each item once, together with the image which has the lowest display_order for that item.
For example, if the item with item_id value of 1 has three images related to it (ie. they all have 1 in the item_id column), I only want the one with the lowest value display_order to be included in the result set.
The data set should have the following columns: items.item_id, items.item_name, images.filename, images.caption.
Can you help? I'm completely stuck!
voidstate