Search Postgresql Archives

Re: Changing a schema's name with function1 calling function2

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

 



On 12/23/23 08:12, Wilma Wantren wrote:
Thank you!
I had already feared that such a variable does not exist (because I had not found it). I think that's a pity, because I suspect that in at least 90% of the cases where a function needs a search_path, this variable would be the value of the search_path, so that in 90% of the cases no change to the search_path would be necessary after renaming the schema.

I would say the issue is with this from your previous post:


"Therefore it would be great if there was a variable which I could set in a search_path (like the variable "$user") which denotes the function's schema and which is only evaluated when the function is executed, i.e. the variable would be the value of the function's search_path in the function's meta data."

search_path can be set(just off the top of head):

postgresql.conf and it's include files
ALTER DATABASE
ALTER FUNCTION
ALTER ROLE
ALTER SYSTEM
At any point by a user/script/function/etc.

Even if such a variable existed you be chasing down the 'correct' version of search_path that had it. Basically where you are now.

Many thanks for the reference to sqitch, I'll have a look at that now.


--
Adrian Klaver
adrian.klaver@xxxxxxxxxxx






[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 Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux