calling functions in pg_temp schema without prefix
<p>In postgres the <code>pg_temp</code> schema is by default on the search path.
As explained by Tom Lane <a href="https://www.postgresql.org/message-id/12887.1287636459%40sss.pgh.pa.us" rel="nofollow">here</a> functions in the <code>pg_temp</code> schema are not callable by default without a prefix for security reasons.</p>

<p>However he states that in order to call functions in the <code>pg_temp</code> schema without a prefix you have to explicitly add the temp schema to the search path. Unfortunately as of postgresql 9.4 this doesn't seem to work anymore.</p>

<pre><code>set search_path to pg_temp,public;
-- create function in the temp schema
create function test_fun() returns int as $$ select 1; $$ language sql;
-- results in "function test_fun() does not exist"
select test_fun();
-- works perfectly
select pg_temp.test_fun();
</code></pre>

<p>Is there any way to call functions in the pg_temp schema without prefixing them?</p>

<p>This would be highly convenient for developing new functions.</p>