On Mon, 14 Apr 2003, Jay O'Connor wrote:
> At 12:27 PM 04/14/2003 -0600, scott.marlowe wrote:
>
> >Crap, sorry, you're right. You'll need to use a rule. Rules are simpler
> >than triggers / functions. They're described in the programmer's guide,
> >section 13 for 7.3.2.
>
> Problem is RULEs don't seem to have the sophistication I need (boolean
> logic...search for a record and if it doesn't exists, insert it, then
> re-SELECT on the same table)
I think it might be doable anyway. Since rules allow where clauses, maybe
you could make one that had a where clause to test to see if the row
existed and if not then it calls a function to create the row.
I'm busy wrestling an import script to the ground right now, but I'll try
to see if I can make something like that work when I get a minute.