Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9201323
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T22:58:43+00:00 2026-06-17T22:58:43+00:00

I am currently attempting to create a chat program aimed for 1000-1500 users. I

  • 0

I am currently attempting to create a chat program aimed for 1000-1500 users. I was wondering if i should create a separate table for each user, as in a table for each users friends, message or should just create one include all table and store everything there, as in which solution would be more efficient? I believe having multiple tables for each users personal details would be more efficient so that most queries i run are run on tables with small amount of data.

Could anyone tell me if i am wrong?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T22:58:45+00:00Added an answer on June 17, 2026 at 10:58 pm

    You are very wrong. Ideal way should be to have one single table for users. Even for companies like ebay where there are millions of users; the way those users are distributed are like all users starting with A in a single table … As @Matt mentioned we cannot create tables where x is not a bounded number.

    Along with that table you can have a table Messages which will have a column UserName which will be a foreign key pointing to your user table.

    Cleanest possible solution can be a bit tricky for maintaining friends list. A workaround solution can be to have a column in User table which will have comma separated ids of Friends ( which are again users in same table ). If you do not want any limits on friends list: You could just create another table Friends having two columns userid, friendId. Both these columns will be foreign keys on User table. Now, query will be simple select * form Friends where userid=<user> . This table might be huge; but that is where index comes into picture. You can create an index on userid column and query results will be super fast even with lots of records.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm attempting to create Data Access Layer for my web application. Currently, all datatables
I am currently attempting to push html updates to a page for a user
I am currently attempting to create a RelativeLayout, embedded in a Scrollview (so the
_ENV currently hates using classes. I'm attempting to create a Latin kind of Lua,
I am currently attempting to create a Perl webspider using WWW::Mechanize. What I am
I'm new to android and am currently attempting to create a simple application which
I'm currently attempting to make a program for a project I'm working on. I
I am currently attempting to create a bash script that will check inside of
I'm currently attempting to create an HtmlHelper which takes in the same kind of
I am attempting to create a system to validate a user's username and password.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.