Use the CURRENT_USER function to identify the active user within the database server.
SELECT CURRENT_USER AS "User";
User ------- cfehily
You can use user functions in SELECT, WHERE, and ORDER BY clauses or anywhere an expression is allowed.
SQL also defines the SESSION_USER and SYSTEM_USER functions. The current user indicates the authorization identifier under whose privileges SQL statements currently are run. (The current user may have permission to run, say, only SELECT statements.) The session user indicates the authorization ...