Updating rows (automatically) that are selected

Поиск
Список
Период
Сортировка
От Assad Jarrahian
Тема Updating rows (automatically) that are selected
Дата
Msg-id 4bd3e1480601181326u166dabd7i3770c6d6024d3a6c@mail.gmail.com
обсуждение исходный текст
Ответы Re: Updating rows (automatically) that are selected  (Bruno Wolff III <bruno@wolff.to>)
Список pgsql-general
Hello,
  I have a table called X
it contains 3 fields of importance(amongst others).
time (timestamp), snooze (int) , inbox (int)

The time column sometimes has null values.
What I want is that every time a row is selected, if the time is a
null value, it is set to now() and  snooze is set to 0 and inbox to 1

How would I go about doing this. I looked into Creating Rules, but I
am not sure if this will work.

Please Advice. Much thanks in advance.
-assad

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

Предыдущее
От: Alex Turner
Дата:
Сообщение: Re: Postgres Wierdness
Следующее
От: "Don Hayes"
Дата:
Сообщение: 32/64 architectures for backup/WALs