Date Of Entry and Date Of Change

Поиск
Список
Период
Сортировка
От Dale Seaburg
Тема Date Of Entry and Date Of Change
Дата
Msg-id D23B5780-9DC1-49E6-97E9-375F853FA498@verizon.net
обсуждение исходный текст
Список pgsql-novice
I need to be able to establish the Date of Entry (INSERT) and Date of
Change (UPDATE) of a row to a table.  I have added to my table two
columns, named 'doe' and  'doc' respectively.  For sake of
discussion, let's call the Table 'instr'.  What would be the best
method of added the current timestamp (date and time) to each of
these two new columns.  In my mind, the timestamp would need to be
added just before the row was INSERTed or UPDATEd to prevent any
"race" condition.

I have looked at Triggers and Functions in the pgAdmin helps, but it
is confusing at best, how to arrive at a solution.  Any help would be
appreciated.  Perhaps, a simple example to get me headed in the right
direction.

Regards,

Dale Seaburg



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

Предыдущее
От: "Obe, Regina"
Дата:
Сообщение: Re: How to save a image file in a postgres data field.
Следующее
От: Dale Seaburg
Дата:
Сообщение: Re: Date Of Entry and Date Of Change