Re: [HACKERS] Intended behaviour of SET search_path with SQL functions?

2008-03-06 Thread Tom Lane
Richard Huxton <[EMAIL PROTECTED]> writes: > => CREATE OR REPLACE FUNCTION func_b() RETURNS SETOF int AS $$ > SELECT id FROM table_a; > $$ LANGUAGE sql SET search_path = alpha; > ERROR: relation "table_a" does not exist Hmmm, I'll bet the validator forgets to apply the parameter modifica

[HACKERS] Intended behaviour of SET search_path with SQL functions?

2008-03-06 Thread Richard Huxton
=> SHOW search_path; search_path - beta (1 row) => CREATE OR REPLACE FUNCTION func_b() RETURNS SETOF int AS $$ SELECT id FROM table_a; $$ LANGUAGE sql SET search_path = alpha; ERROR: relation "table_a" does not exist CONTEXT: SQL function "func_b" => \d table_a Did not fi