How to deal with almost recurring data?

Поиск
Список
Период
Сортировка
От matthias@cmklein.de
Тема How to deal with almost recurring data?
Дата
Msg-id E1CU4hp-0005da-00@www.strato-webmail.de
обсуждение исходный текст
Ответы Re: How to deal with almost recurring data?  (Csaba Nagy <nagy@ecircle-ag.com>)
Re: How to deal with almost recurring data?  (Richard Huxton <dev@archonet.com>)
Список pgsql-general
I am creating a database which is supposed to contain many data entries
(events) that differ only in the date they occur.

So let's say event 1 occurs every Monday, Tuesday and Sunday between
January 1st and May 30th 2005.

How do I store and manage such data in a meaningful way?

The simple idea would be to store the event itself in one table and have
another table containing all the dates (all Mondays, Tuesdays and Sundays
between 2005-01-01 and 2005-05-30) plus a foreign key to event_ID =>
(date, event_id).

The problem is that we are dealing with several tenthousand events,
resulting in several million single dates if I stored it in the described
manner.

That is why I would like to know if there is a better way to store and
manage such information?

Thanks

Matt

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

Предыдущее
От: Jeff Eckermann
Дата:
Сообщение: Re: Last value inserted
Следующее
От: Jeff Eckermann
Дата:
Сообщение: Re: OID's