Thread: execute function after user connect

execute function after user connect

From
John DeSoi
Date:
Is there a mechanism to execute a function after the user connects to
the database? I would like to set the schema path based on the user's
group membership. It would also be nice to log to a table on
connect/disconnect.

Thanks,

John DeSoi, Ph.D.


Re: execute function after user connect

From
Bruno Wolff III
Date:
On Fri, Apr 02, 2004 at 11:58:42 -0500,
  John DeSoi <jd@icx.net> wrote:
> Is there a mechanism to execute a function after the user connects to
> the database? I would like to set the schema path based on the user's
> group membership. It would also be nice to log to a table on
> connect/disconnect.

You can set the schema path based on the user or the database (but not
both at once), using ALTER USER or ALTER DATABASE.

Re: execute function after user connect

From
Date:
> On Fri, Apr 02, 2004 at 11:58:42 -0500,
>   John DeSoi <jd@icx.net> wrote:
>> Is there a mechanism to execute a function after the user connects to
>>  the database?

Something like an "AFTER CONNECT" trigger (might as well as for a "BEFORE
DISCONNECT" trigger, too!). I've inquired about this feature in the past
and can think of what seem to be very useful uses.

Unfortunately, my skill set is such that I must rely on the kindness of
others to actually see it implemented...

Eagerly awaiting that day.

~Berend Tober