Jump to content

Recommended Posts

Hi, I have a question about mysql:

 

I'm trying to create a website that will have complicated mysql. It will have user log in, and track a various elements of each user. (A LOT of different things). What is the best way to go around with this? Should I have a super huge table with everything? Or should I have multiple tables per user?

 

I'm not worried about the amount of space the mysql takes up. I'm more worried about the effiency and how well the querying of the data works. I do not want future lag, even with a lot of traffic. So what would be the best structure of my site?

 

Finally, my host says I can have "50 simultaneous connections for each user" (mysql) do you have any clue what that means?

Link to comment
https://forums.phpfreaks.com/topic/51024-mysql-help/
Share on other sites

What do you mean? You are worried that mysql will crash if it tries to access 1 table with a large array of information?

 

I wouldn't worry about it unless you are query overloading..

 

No. It wouldn't crash over a large table, but over a LOT of requests!!! You see I predict (hope) this site will become popular. EAch page will require a mysql query. Now, I am worried it will crash, or give me a lag if there are soo many requests. So what is the best table structure.

 

There would be many elements that would be added too. Like post count, and rep. stuff like that. I was thinking it would be easier for each user to have their own table for each set of stuff. Is this a good idea? I WILL SAY, THAT ONE TABLE, is completely unworkable.

Link to comment
https://forums.phpfreaks.com/topic/51024-mysql-help/#findComment-251078
Share on other sites

No. It wouldn't crash over a large table, but over a LOT of requests!!! You see I predict (hope) this site will become popular. EAch page will require a mysql query. Now, I am worried it will crash, or give me a lag if there are soo many requests. So what is the best table structure.

 

There would be many elements that would be added too. Like post count, and rep. stuff like that. I was thinking it would be easier for each user to have their own table for each set of stuff. Is this a good idea? I WILL SAY, THAT ONE TABLE, is completely unworkable.

 

No, I'd say use a column for each different information for the user, not a whole new table, that could create lag because you'd have to call up a lot of tables.

Link to comment
https://forums.phpfreaks.com/topic/51024-mysql-help/#findComment-251081
Share on other sites

No, I'd say use a column for each different information for the user, not a whole new table, that could create lag because you'd have to call up a lot of tables.

 

Okay, I see what you mean. But I'm a bit confused. If there are about 500 requests for that one table, wouldn't it cause more problems, then split it up between tables?

 

Also, if there ever is a lag, how could I increase mysql performance?

Link to comment
https://forums.phpfreaks.com/topic/51024-mysql-help/#findComment-251083
Share on other sites

Okay, I see what you mean. But I'm a bit confused. If there are about 500 requests for that one table, wouldn't it cause more problems, then split it up between tables?

 

Also, if there ever is a lag, how could I increase mysql performance?

 

Probably not. If a user has individual info, then you'd just be calling one table. If you want some other table, it wouldn't be completely user related so it wouldn't matter if there were 500 requests for a single table. You just need to make arrays that include calling up a certain table. If you're confused about that, I'll try to help describe it further...

Link to comment
https://forums.phpfreaks.com/topic/51024-mysql-help/#findComment-251086
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.