Getting linux $USER (and perhaps other env vars) in PL/pg-sql?

From: "Gauthier, Dave" <dave(dot)gauthier(at)intel(dot)com>
To: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Getting linux $USER (and perhaps other env vars) in PL/pg-sql?
Date: 2009-08-07 19:08:45
Message-ID: 482E80323A35A54498B8B70FF2B8798004156B82D3@azsmsx504.amr.corp.intel.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi:

Running 8.3.4 on Linux.

From inside a stored procedure, is there a way to capture the linux user (environment var = $USER) that is attached to the DB?

A simplistic (though meaningless) example would be echo $USER from something like "select get_linux_user()".

Thanks
-dave

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Sam Mason 2009-08-07 19:38:07 Re: Getting linux $USER (and perhaps other env vars) in PL/pg-sql?
Previous Message Bill Bartlett 2009-08-07 18:12:30 Re: psql and Emacs on Windows