Re: get username of user calling function?

From: George Nychis <gnychis(at)cmu(dot)edu>
To: David Legault <legault(dot)david(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: get username of user calling function?
Date: 2007-03-01 17:35:29
Message-ID: 45E70EE1.6010303@cmu.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

David Legault wrote:
>
>
> See the EXECUTE function in the pl/pgSQL language in the docs for dynamic
> queries.
>
So it turns out that in a SECURITY DEFINER the current_user is the owner of the function.
I had to use session_user and it works now :)

- George

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Willy-Bas Loos 2007-03-01 17:42:27 Re: cast bytea to text
Previous Message Bill Moran 2007-03-01 17:33:52 Re: supporting 2000 simultaneous connections.