On Mon, May 7, 2018 at 2:35 PM, David Gauthier <davegauthierpg(at)gmail(dot)com>
wrote:
> Hi:
>
> At the psql prompt, I can do something like...
> "select \! id -nu"
> ...to get the uid of whoever's running psql.
>
> I want to be able to run a shell command like this from within a stored
> procedure. Is there a way to do this ?
>
>
In core, you can probably use the untrusted version of Perl, Python, or
Tcl to accomplish your goal. SQL and pl/pgSQL do not provide that
capability.
David J.