Search Postgresql Archives

Re: Function `set_config` doesn't work in with query?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>>>>> "Zexuan" == Zexuan Luo <spacewanderlzx@xxxxxxxxx> writes:

 Zexuan> For instance:
 Zexuan> ```
 Zexuan> with t as (
 Zexuan>     select set_config('blah', '1', false)
 Zexuan> )
 Zexuan>     select current_setting('blah');

A CTE containing a SELECT query which is not referenced anywhere will
not be executed, even if it contains volatile functions. (CTEs
containing INSERT/UPDATE/DELETE that are not referenced _will_ still be
executed.)

-- 
Andrew (irc:RhodiumToad)




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux