Updating column on row update

Поиск
Список
Период
Сортировка
От Thom Brown
Тема Updating column on row update
Дата
Msg-id bddc86150911221150q35cf297di3357981061cf3286@mail.gmail.com
обсуждение исходный текст
Ответы Re: Updating column on row update
Список pgsql-general
Hi,

This should be simple, but for some reason I'm not quite sure what the solution is.  I want to be able to update the value of a column for rows that have been updated.  More specifically, if a row is updated, I want it's modified_date column to be populated with the current time stamp.  I've looked at triggers and rules, and it looks like I'd need to create a function just to achieve this which seems incredibly clumsy and unnecessary.  Could someone enlighten me?

Thanks

Thom

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Planning problem: pushing conditions through GROUP BY
Следующее
От: Thom Brown
Дата:
Сообщение: Re: Updating column on row update