Re: [HACKERS] Regression Tests (opr) Sanity

2010-11-25 Thread Tom Lane
Dimitri Fontaine dimi...@2ndquadrant.fr writes:
 The pg_execute_from_file() function is designed to work with either a
 filename as its sole argument, or the filename and a VARIADIC text list
 of arguments containing placeholder names and values. It works fine with
 two entries in pg_proc using the same backend function, and it looks
 like the following from a psql shell:

Just make two pg_proc entries that are pointing at two C functions.
The C functions can call a common subroutine after extracting their
arguments.

regards, tom lane

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers


Re: [HACKERS] Regression Tests (opr) Sanity

2010-11-25 Thread Dimitri Fontaine
Tom Lane t...@sss.pgh.pa.us writes:
 Just make two pg_proc entries that are pointing at two C functions.
 The C functions can call a common subroutine after extracting their
 arguments.

Mmmm, ok, will adapt the idea to the current code, where the extracting
is mingled into the processing. Thanks for the idea, that's much simpler
this way. Cleaner ain't always betterĀ :)

Regards,
-- 
Dimitri Fontaine
http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers