Large database design advice

Поиск
Список
Период
Сортировка
От Joe Kramer
Тема Large database design advice
Дата
Msg-id b4c00a110608240905j344834adl79c510d56fcbbc2@mail.gmail.com
обсуждение исходный текст
Ответы Re: Large database design advice  ("Harald Armin Massa" <haraldarminmassa@gmail.com>)
Список pgsql-general
Hello,

I am designing database for a web product with large number of data records.

- Few tables but number of objects is tens-hundreds of thousands.
- less than 100 queries per second.

The application has  basically tens thousands of (user) accounts,
every account has associated hundreds of items.

My initial thought is to design it like this:

Table: account
---------------------
account_id BIGSERIAL


Table: item
---------------------
account_id BIGINT
item_id INT

Questions:

Should table account be designed with BIGSERIAL key, or if it's going
to have six-digit number of records, other method should be used?

Should I use compound key for table item (account_id+item_id) or
item_id should be BIGSERIAL and global sequence with key being only
item_id?

How generally this design will hold up against this amount of data?

Thanks.

В списке pgsql-general по дате отправления:

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: invalid byte sequence ?
Следующее
От: "Jasbinder Bali"
Дата:
Сообщение: Dynamic loading (datatype mismatch)