[SQL] Accessing field of OLD in trigger

2007-10-11 Thread Daniel Drotos
Hi, I'm working on a row level plpgsql trigger running after delete, using a 8.0.3 server. It gets a parameter which is a field name of the OLD record. How can that field be accessed? I'd like to do something like: for recvar in 'select OLD.'||quote_ident(TG_ARGV[0])... Daniel

Re: [SQL] Refactored queries needing validation of syntactic equivalence

2007-10-11 Thread Richard Huxton
Mike Adams wrote: Hello! I'm a long time lurker who has become responsible for maintaining / updating utility queries at work. I've reworked two queries (as text attachment as they are wide lines) to enhance the planner's chance of speeding up the queries (Oracle8i's). Well, I can't say it's