If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > MySQL > new to database

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-03-10, 10:56
evil_master2120 evil_master2120 is offline
Registered User
 
Join Date: Apr 2010
Posts: 2
new to database

Hi All,

Thank you for reading the post, I am creating a new test application with mysql database. application will have a simple registration process and will allow user to login as well.

Is it a good idea to have two seperate tables one for registration and one for login?

I am thinking of creating two tables, login & registration. application will write two insert statements one into login table and other to registration table. login table will handle only user try to login their queries and registration table wil handle only registration process.

Do you guys think is it a best practice. Also was thinking if all information written to registration can written to another table which can be used for viewing profile.

I dont know is it good practice to have too tables with similar type of data, only my reason of doing is not too to do too many queries to one table or??

I hope you understand....I will wait for your reply.
Reply With Quote
  #2 (permalink)  
Old 04-03-10, 11:11
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,525
best practice would be a single table

why do you feel that duplicating the data into two tables would be a good idea?
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
  #3 (permalink)  
Old 04-03-10, 11:14
evil_master2120 evil_master2120 is offline
Registered User
 
Join Date: Apr 2010
Posts: 2
oh well i was thinking that alot of queries will not only going to one table which is the main reason i was thinking of one table. but if you have an application with 6000 users using it at the same time, won't it affect the database or make the database crash or anything like that
Reply With Quote
  #4 (permalink)  
Old 04-03-10, 11:36
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,525
Quote:
Originally Posted by evil_master2120 View Post
... won't it affect the database or make the database crash or anything like that
the database engine can take it

10,000 accesses per second is possible

however, you have to make sure you have the hardware to support whatever it is you're expecting to do

don't automatically assume that you have to design the database to overcome a perceived performance problem

do a search for the phrase "premature optimization"
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On