I know that I could certainly make this a heck of a lot easier. Of course I could just create one table named "Products" and put all 90 fields in that one table and be done with it. The part that bothers me about this is the time it will take the database to retrieve the records once that particular table has 40,000 records. Keep in mind that there are going to be approximately 15 other tables in the database that all work to make this Web-based program a success. The database will be working quite hard and I want to make it run as efficiently as possible.
So, are you saying that it is better to have only one table instead of four with my project? I'm confused by this because I used to work with this guy that told me it is better to create more tables when you have a lot of fields (e.g. 90 fields) with thousands (e.g. 40,000) of records that may be used as part of a multitude of queries. He said that the database has to work much harder to filter through all of the fields (e.g. 90 fields) in a single table than it does to filter through multiple tables where the primary keys or unique identifiers are the same. He told me that not a lot of people are aware of this and it is a common mistake when creating databases. I'm not saying that you're wrong, but you didn't give me a reason as to why one table is "practically" better than four for my particular project. I understand that querying four tables seems like more work than having to query just one table, but I was told that it was better from a database performance aspect. I mean heck, the guy that told me how I should build my database has worked on major programming projects for M.I.T., he has his MCSD, a Master's Degree in Mechanical Engineering, and currently works as a mechanical engineer for the North American Master Distributor for Ericsson Fiber Optics Equipment. He also develops the software that runs the equipment he engineers. He is an expert with C, C++, C#, PHP, and Postgre SQL. Unfortunately, he is extremely busy to help me and we don't work together anymore. This is too big of a project to mess up! I really need the advice of someone who knows exactly what they are talking about. I know that sounds rough and I'm not suggesting that you don't know what you're talking about. I respect everyone's knowledge in here. I just wanted to make it clear that I don't just need a quick fix or a band aid to patch up my little problem. This is really a huge deal. Any suggestions? If you can tell me why only one table is better from a "technical" standpoint, I will give it a shot. I just know that I have been literally panicking because I am not that good of a programmer. I'm just starting to learn how to do more than just the basic stuff when it comes to PHP & MySQL. This is the reason I joined this group. Respectfully, William --- In [email protected], Pete <[EMAIL PROTECTED]> wrote: > > In message <[EMAIL PROTECTED]>, wrwatson2003 > <[EMAIL PROTECTED]> writes > >I do know for a fact that there will be over 10,000 records put into > >the database immediately once the project is finished. > > There will be about 90 fields, one for each checkbox. Each field will > be quite small - assuming that you are using MySQL, they will be > probably be TinyInts, so won't take a lot of space. > > > I don't think > >having 900,000 fields to filter through in one table is a good idea! > > I can't figure out what you mean here... > > >I was told by an MCSD that the more tables I have, the better. > > No, because YOU will have to open 4 tables instead of opening one! > > >I'm not really sure why I thought I would need 4 tables. I'm looking > >for a way to minimize the number of fields my queries have to search > >to retrieve data. > > You have actually made it more complicated, because now you have the > same number of fields, but spread across 4 tables. > > >Can you help me? What do you suggest I do? > > Create 1 table! If you really need to, create a field "oldtablenumber" > which will show which table the records "used" to be in, just to keep > your head together. > > -- > Pete Clark > > http://www.hotcosta.com > http://www.spanishholidaybookings.com > ------------------------ Yahoo! Groups Sponsor --------------------~--> AIDS in India: A "lurking bomb." Click and help stop AIDS now. http://us.click.yahoo.com/9QUssC/lzNLAA/TtwFAA/CefplB/TM --------------------------------------------------------------------~-> The php_mysql group is dedicated to learn more about the PHP/MySQL web database possibilities through group learning. Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/php_mysql/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
