Jump to content

Is there a speed difference?


astralaaron
 Share

Recommended Posts

If there is a table that has 10 fields, and you wanted to select only 2 of the fields, is it slower than if the table only had 2 fields and using a select *?

 

I am wondering if I should have my members table have more fields or to create a separate table for their account profile information

Link to comment
Share on other sites

Searches are mostly about focus and the amount of data that has to be sifted. Target only the data that has the info you need in tables that don't contain a bunch of irrelevant data or data that requires a lot of calculation and your queries will usually be as fast as you can make them

Link to comment
Share on other sites

Searches are mostly about focus and the amount of data that has to be sifted. Target only the data that has the info you need in tables that don't contain a bunch of irrelevant data or data that requires a lot of calculation and your queries will usually be as fast as you can make them

 

Sorry, I have a difficult time wrapping my head around things some times.. When you say "tables that don't contain a bunch of irrelevant data" that means that the table with only the two fields would be faster than targeting the table that has 10 fields? The 8 additional fields are irrelevant to this specific search..

 

 

Thank you for responding.

Link to comment
Share on other sites

I doubt that the width of the table would have much effect as long as you aren't indexing these columns or pulling in a large amount of data. Obviously it is slower to handle more data vs. less data. Why don't you simply benchmark a pair of test cases?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...