Re: One Large Table or Multiple DBs?

From: Ron Johnson <ron(dot)l(dot)johnson(at)cox(dot)net>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: One Large Table or Multiple DBs?
Date: 2007-07-13 03:00:55
Message-ID: 4696EAE7.306@cox.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 07/09/07 16:18, Mike wrote:
> Hi,
>
> What is efficient approach toward storing a web application's user
> data. How do applications such as basecamp, SalesForce or QuickBooks
> online store their data? Is it in one DB with huge tables each record
> having a user account's foreign key or do they create a separate
> database for each of their accounts? Which one is more efficient? My
> guess was in one large DB with large tables.

How big is "big"?

What is "efficient"? Speed, management, upgrades, backups, scalability?

If each customer has 80GB of data, then separate databases are the
way to go, since it eases scalability and allows for parallel
backups. But then upgrades must be applied to each of thousands of
databases. If each customer has 100MB of data, then unified tables
keyed off of account number would be simpler.

In between is schema-per-account. But upgrades are still a chore.

--
Ron Johnson, Jr.
Jefferson LA USA

Give a man a fish, and he eats for a day.
Hit him with a fish, and he goes away for good!

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Gauthier, Dave 2007-07-13 03:36:28 Re: returns setof rec... simple exampe doesn't work
Previous Message Jorge Godoy 2007-07-13 02:54:37 Re: Accent-insensitive search