Re: custom serial number

Поиск
Список
Период
Сортировка
От A. Kretschmer
Тема Re: custom serial number
Дата
Msg-id 20081119133719.GA8238@a-kretschmer.de
обсуждение исходный текст
Ответ на Re: custom serial number  (mahmoud ewiwi <mahmoud_ewiwi@yahoo.com>)
Список pgsql-sql
am  Wed, dem 19.11.2008, um  0:52:07 -0800 mailte mahmoud ewiwi folgendes:
> Thank you very much, it works fine with me , but how can i restart the sequence at the start of each month, or should
ido it programatically?
 

For instance, check if a record for the actual month are in the table.
If not, use setval() to reset the sequence to 1.

http://www.postgresql.org/docs/8.3/interactive/functions-sequence.html


Andreas
-- 
Andreas Kretschmer
Kontakt:  Heynitz: 035242/47150,   D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID:   0x3FFF606C, privat 0x7F4584DA   http://wwwkeys.de.pgp.net


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

Предыдущее
От: "Bart van Houdt"
Дата:
Сообщение: Query to retrieve all indexed columns
Следующее
От: "Ryan Wells"
Дата:
Сообщение: Re: Left Join Question