Re: Invoking user of the function with SECURITY DEFINER

2019-04-10 Thread Олег Самойлов
Looked like a bug. > 25 нояб. 2018 г., в 14:50, Madan Kumar написал(а): > > Got it.. > In my case i was getting session_user in declare section and trying to > validate later which always resulted in the function owner. > DECLARE > user text := SESSION_USER; > > So using it within the B

Re: Invoking user of the function with SECURITY DEFINER

2018-11-25 Thread Madan Kumar
Got it.. In my case i was getting session_user in declare section and trying to validate later which always resulted in the function owner. DECLARE user text := SESSION_USER; So using it within the BEGIN; ...; END; clause worked for me. Thanks. Warm Regards, Madan Kumar K

Re: Invoking user of the function with SECURITY DEFINER

2018-11-24 Thread raf
Laurenz Albe wrote: > Madan Kumar wrote: > > How to get the user who is invoking the function with SECURITY DEFINER? > > When we define the function to be SECURITY DEFINER, it will execute in the > > context of the user who created it. Let's say I've given execute permission > > for this function

Re: Invoking user of the function with SECURITY DEFINER

2018-11-22 Thread Laurenz Albe
Madan Kumar wrote: > How to get the user who is invoking the function with SECURITY DEFINER? > When we define the function to be SECURITY DEFINER, it will execute in the > context of the user who created it. Let's say I've given execute permission > for this function to other users and wish to kno