| От | Itai Zukerman |
|---|---|
| Тема | Re: Conditional rule? |
| Дата | |
| Msg-id | 87zon2tt20.fsf@matt.w80.math-hat.com обсуждение исходный текст |
| Ответ на | Re: Conditional rule? (JanWieck@t-online.de (Jan Wieck)) |
| Список | pgsql-sql |
> > CREATE RULE newsrule AS ON INSERT TO news
> > WHERE new.publishtime NOTNULL DO
> > INSERT INTO news_unpublished VALUES (new.id);
>
> The following happens:
> rules=# insert into news (title, time) values('Hei', now());
> ERROR: <unnamed> referential integrity violation - key referenced from
> news_unpublished not found in news
I noticed this, too.
More generally, I've found that whereas rules initially looked like a
great thing to use, in practice I have really no idea what they're
going to do. And I find their description in the programmer's guide
confusing. Is there any better rules tutorial out there?
-itai
В списке pgsql-sql по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера