Re: determining OPS$ username in Forms

From: <dahlsg_at_my-deja.com>
Date: Wed, 01 Sep 1999 13:25:43 GMT
Message-ID: <7qj9g8$h6m$1_at_nnrp1.deja.com>


In article <7qgn19$kff$1_at_nnrp1.deja.com>,   markp7832_at_my-deja.com wrote:
> In article <1761dd4a.ebff501d_at_usw-ex0107-050.remarq.com>,
> Gary <gary.perkinsNOmzSPAM_at_nt.gov.au> wrote:
> > Howdy, Is there a way to get around the problem of
> > GET_APPLICATION_PROPERTY(USERNAME) only returning a null
> > for OPS$ accounts?? Something like SQLPlus' show user would
> > be just dandy.
> >
> > Cheers
> > GP
> >
> > * Sent from RemarQ http://www.remarq.com The Internet's Discussion
> Network *
> > The fastest and easiest way to search and participate in Usenet -
> Free!
> >
> I do not develop in forms, but try the following:
> Use the psuedo column user:
> select user into :form_username from sys.dual;
>
> I suspect that will work since it works for OS authenticated sessions
> on our system. If that fails you can try:
>
> select se.osuser
> from v$session se
> where se.audsid = userenv('SESSIONID');
>
> I hope this helps.
> --
> Mark D. Powell -- The only advice that counts is the advice that
> you follow so follow your own advice --
>
> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.
>

This is what I use when I want to see everyone that is on: SELECT SUBSTR(USERNAME,1,8) "USER", osuser, SUBSTR(MACHINE,1,8)"MACHINE",
    SUBSTR(PROGRAM,1,8) "PROGRAM" , STATUS "STATUS " FROM V$SESSION where username is not null order by 1

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't. Received on Wed Sep 01 1999 - 15:25:43 CEST

Original text of this message