I'm no expert on massive amounts of data, but if you index the field which you are querying by (say you're relating the images to the product via productID), then I'd index the productID field of tblPics.
Indexing (to the best of my limited knowledge) speeds up the querying process, and slows down modifications to the table... sicne you really need performance at display time, not adding/updating time, I think this will help. I know of indexes making product searches of 50,000 products, even in flat (indexed) files work really fast, so this would be an ideal first step. Justin French on 12/04/02 7:31 PM, W. Enserink ([EMAIL PROTECTED]) wrote: > Hi all, > > > i'm currently busy with db design. Since I have not worked with these > amounts of content data I have a few questions. > > > I have 2 tables: a table filled with records about products (currently 2200 > records) (tblProducts) > The next table is a table with pictures referring to product_ID's. (tblPics) > (3600 records). > Some products have more than 1 picture. I'm on apache server with mySql db. > > > Now about my db design question: > > can I better use 1 table (the tblProducts) where I store PictureNames in 1 > field, seperated by commas or whatever or should I use the tblPics as a > lookup table. > > The advantages to use tblPics as a lookup are quite clear, but each time I > want to show the pics belonging to a certain product I have to query the > lookuptable with it's 3600 records. Does this consume a lot of time?? Or > isn't 3600 records (with 8 columns) a lot. > > > > Thanx for your opinion > > Wilbert Enserink > > ------------------------- > Pas de Deux > Van Mierisstraat 25 > 2526 NM Den Haag > tel 070 4450855 > fax 070 4450852 > http://www.pdd.nl > [EMAIL PROTECTED] > ------------------------- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php