members db or table?
-
I have multiple websites and i am planning to put all on the same web host. All will be storing data on mySQL databases. My question.... if I want to use the same authentication details (user id and password) for all websites, which way you prefer: 1. Create the same member table in every database related to website, for example in websiteDB1, websiteDB2, etc? so every websiteDB will have membersDB? but technically all memberDB are the same because it's storing the same userIDs and passwords? 2. Create a separate database called memberDB and connect to it from website1 and website2 when the user wants to authenticate? what's you suggestion? Thanks, Jassim
-
I have multiple websites and i am planning to put all on the same web host. All will be storing data on mySQL databases. My question.... if I want to use the same authentication details (user id and password) for all websites, which way you prefer: 1. Create the same member table in every database related to website, for example in websiteDB1, websiteDB2, etc? so every websiteDB will have membersDB? but technically all memberDB are the same because it's storing the same userIDs and passwords? 2. Create a separate database called memberDB and connect to it from website1 and website2 when the user wants to authenticate? what's you suggestion? Thanks, Jassim
This depends a lot on the expectations of your users: do they know that the same user name and password let them log in to multiple web sites, or do they expect to be able to change their password on website#1, and keep the old password on website#2? If user name and password must be kept synchronized for all web sites, then there should be only one table; if each web site should have its own pair of user name and password, then obviously there should be multiple tables.
-
This depends a lot on the expectations of your users: do they know that the same user name and password let them log in to multiple web sites, or do they expect to be able to change their password on website#1, and keep the old password on website#2? If user name and password must be kept synchronized for all web sites, then there should be only one table; if each web site should have its own pair of user name and password, then obviously there should be multiple tables.
what about using a separate db for the users profiles but instead of having a single record for the user id and password I'll use multiple records with a flag indicating which service this user id and password belongs to?
-
what about using a separate db for the users profiles but instead of having a single record for the user id and password I'll use multiple records with a flag indicating which service this user id and password belongs to?
It's a viable alternative, too, but given that you were planning on creating multiple databases anyway, this would seem like an extra maintenance headache. On the other hand, if your database would store little or no site-specific data (i.e. you're creating them almost specifically to support user logins), then using a single database with a flag in a table is definitely a better choice. A lot of this depends on your requirements: once you know what you are trying to achieve, doing the technical side becomes nearly mechanical :)
-
It's a viable alternative, too, but given that you were planning on creating multiple databases anyway, this would seem like an extra maintenance headache. On the other hand, if your database would store little or no site-specific data (i.e. you're creating them almost specifically to support user logins), then using a single database with a flag in a table is definitely a better choice. A lot of this depends on your requirements: once you know what you are trying to achieve, doing the technical side becomes nearly mechanical :)
actually it's different websites including personal site so i thought why should i keep all in one database and the scroll through the tables and stored procedures and ... and.... I am using mySQL and i thought it would be easier to have separate database for every website instead of putting all together or even create a schema because that might end up to large database size? what do you think?
-
actually it's different websites including personal site so i thought why should i keep all in one database and the scroll through the tables and stored procedures and ... and.... I am using mySQL and i thought it would be easier to have separate database for every website instead of putting all together or even create a schema because that might end up to large database size? what do you think?
If you have different databases for different web sites, and your users would need separate logins to each web site, then keeping the login data with the rest of the site data sounds like a better choice from the design perspective.
-
I have multiple websites and i am planning to put all on the same web host. All will be storing data on mySQL databases. My question.... if I want to use the same authentication details (user id and password) for all websites, which way you prefer: 1. Create the same member table in every database related to website, for example in websiteDB1, websiteDB2, etc? so every websiteDB will have membersDB? but technically all memberDB are the same because it's storing the same userIDs and passwords? 2. Create a separate database called memberDB and connect to it from website1 and website2 when the user wants to authenticate? what's you suggestion? Thanks, Jassim