Re: [HACKERS] INSTEAD OF trigger on VIEWs

2005-05-24 Thread Russell Smith
On Tue, 24 May 2005 01:26 am, --= Tono =-- wrote: I have tried using INSTEAD rules but there are some conditional logic that needs to happen inside the rule (performing counts, getting and storing the primary key of the master record etc.). AFAIK, rules only allows conditional logic to be

[HACKERS] INSTEAD OF trigger on VIEWs

2005-05-23 Thread --= Tono =--
Is there any plans to create an INSTEAD OF trigger on VIEWS? I have view which consists of a master and detail table. When a row is inserted into the view, the view needs to figure out if the master record already exsists. If the record does not exists in the master table, then insert into the

Re: [HACKERS] INSTEAD OF trigger on VIEWs

2005-05-23 Thread Christopher Kings-Lynne
You can probably just create an INSTEAD rule on the view... Chris --= Tono =-- wrote: Is there any plans to create an INSTEAD OF trigger on VIEWS? I have view which consists of a master and detail table. When a row is inserted into the view, the view needs to figure out if the master record

Re: [HACKERS] INSTEAD OF trigger on VIEWs

2005-05-23 Thread Jan B.
I have a similar problem and already considered using RULEs, but I encountered the problem, that I did not find any way to execute procedures from RULEs without using SELECT, which creates always a result set being passed to the application invoking the INSERT, UPDATE or DELETE, even if the

Re: [HACKERS] INSTEAD OF trigger on VIEWs

2005-05-23 Thread Christopher Kings-Lynne
I have a similar problem and already considered using RULEs, but I encountered the problem, that I did not find any way to execute procedures from RULEs without using SELECT, which creates always a result set being passed to the application invoking the INSERT, UPDATE or DELETE, even if the

Re: [HACKERS] INSTEAD OF trigger on VIEWs

2005-05-23 Thread Jan B.
Christopher Kings-Lynne wrote: I have a similar problem and already considered using RULEs, but I encountered the problem, that I did not find any way to execute procedures from RULEs without using SELECT, which creates always a result set being passed to the application invoking the INSERT,

Re: [HACKERS] INSTEAD OF trigger on VIEWs

2005-05-23 Thread --= Tono =--
I have tried using INSTEAD rules but there are some conditional logic that needs to happen inside the rule (performing counts, getting and storing the primary key of the master record etc.). AFAIK, rules only allows conditional logic to be check prior to execution of the rule and not inside the