Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to use database for multiple users/states

Status
Not open for further replies.

SPrelewicz

Programmer
Jul 16, 2001
124
US
I want to implement a shopping cart based on mySQL and CGI Sessions. I want to store the sessions in mySQL with a uniques session id for state maintanence. Here's my question, and I hope I'm not being too thick, though Im sure I am. I'm going to have multiple users (ie web stores) using the cart through my server. In other words, they'll have forms on their side sent to my servers shopping cart script. Do you think its okay to have all the users (web stores, their customers) share the same session table in one broad database, or should I create a separate database for each web store? I will have other tables like state names, etc... Can these be shared or again should I duplicate for each web store. Thanks for taking the time to answer probably a pretty dumb question. Quick answers will be appreciated and noted.

Scott Prelewicz
 
depends on no. of concurrent users. if light, then no problem, if heavier you may want to split them to reduce the workload on the DB. basic plan of attack start as one and then test....

PS state info (like for a drop down) should be in an array on the page....it never changes, so why use resources when its so much easier to build an array and use that

Bastien

Any one have a techie job in Toronto, I need to work...being laid off sucks!
 
That sounds good, thanks for the advice. I like putting the states in an array as well. You see, I'm a sloppy coder who never thinks much about resources ans such :), but I severely need to improve that part of my skill set.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top