Results 1 to 4 of 4
Aug 10, 2007, 10:32 #1
- Join Date
- Jan 2006
- 0 Post(s)
- 0 Thread(s)
Sorting data when fetching individually
I have a list of items, and a list of places, and a list which links the items to places.
My code takes a search input of the place id, and then looks for all items in the table that just links items and places, then takes the line of info from the table which holds the item info (id, name, cost etc).
But i want to sort the data by cost. How can i do this?
items (id, name, cost, type, sell)
places (id, name)
item_places (item id, shop id)
Some items belong in multiple places, all places have multiple items. So i can not put shop id into item table.