Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: How to change the USERID variable?

Re: How to change the USERID variable?

From: Rob Edgar <robedgar_at_mersey.com.hk>
Date: Thu, 6 Aug 1998 20:17:02 +0800
Message-ID: <6qc6rq$ob82@news.hk.linkage.net>


Maybe I didnt explain myself too well.

Of course I know how to create and drop users in Oracle that is not the issue here.

We start off by creating a pool of connections to oracle in a mid tier application under a generic user account. When a user ina front end app needs to do somehting in Oracle one of these "pooled" connections is allocated to hime. However as far as Oracle is concerned the "user" hasnt chnged its still the generic user.

What we would like to do is to change the session variable USERID to the valid oracle account of the user whom we allocated the connection to. We could do this by setting a global variable in oracle to the correct id but it would be a bit neater if we could get the session variable to change. I know this is probably a slim chance but I thought I might ask anyway...

Rob

EXE wrote in message <35C931F8.C5628ED6_at_exesolutions.com>...
>> Is there a way by using PL/SQL to change the USERID variable.
>>
>> We have people who will be consecutively sharing a permanently logged in
>> connection and we would like to be able to reassign the variable as the
>> connction gets allocated out to a user mainly so we can continue to use
it
>> in triggers etc that store the value USERID.
>>
>> I know I could achieve the same thing with a package variable but it
would
>> be a little bit neater if I could set the USERID var instead of creating
my
>> own.
>
>You do not "change" the USERID. You CREATE them and DROP them. Look into
the
>books for the CREATE USER and DROP USER commands.
>
>Regards,
>
>Daniel A. Morgan
>
Received on Thu Aug 06 1998 - 07:17:02 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US