Path: news.easynews.com!easynews!newsfeed.frii.net!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.stueberl.de!newspeer1-gui.server.ntli.net!ntli.net!news11-gui.server.ntli.net.POSTED!not-for-mail
From: Andy Hassall <andy@andyh.org>
Newsgroups: comp.databases.oracle.server
Subject: Re: Creating Tables
Organization: Last minute panic
Message-ID: <8pfadu038otcm8900784e94q8pqb4ms5cr@4ax.com>
References: <Q_jA8.4781$VQ6.602987@news.uswest.net> <ud3jv9ppdne8b@corp.supernews.com> <FulA8.2087$vT1.180441@bgtnsc04-news.ops.worldnet.att.net> <3cd52d5d.11940589@news.online.de>
X-Newsreader: Forte Agent 1.91/32.564
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Lines: 24
Date: Sun, 05 May 2002 15:19:51 +0100
NNTP-Posting-Host: 213.107.104.12
X-Complaints-To: abuse@ntlworld.com
X-Trace: news11-gui.server.ntli.net 1020608391 213.107.104.12 (Sun, 05 May 2002 15:19:51 BST)
NNTP-Posting-Date: Sun, 05 May 2002 15:19:51 BST
Xref: easynews comp.databases.oracle.server:145940
X-Received-Date: Sun, 05 May 2002 07:17:29 MST (news.easynews.com)

On Sun, 05 May 2002 13:19:14 GMT, marc@marcblum.de (Marc Blum) wrote:

>The problem:
>Everywhere in packages and triggers and SELECTs and bla ... we need to
>know the OS-user, which differs from the ORACLE-user. (In that
>context, it's not applicable to create an individual ORACLE-User for
>every person working with the application.)
>
>The solution:
>A packaged function, which returns the OS-User. The package is owned
>by SYS, the package gets GRANT EXECUTE TO PUBLIC and a PUBLIC SYNONYM.
>This one is the single only synonym in our whole application suite.
>
>The question:
>Am I evil? Do I have to go to church and pray to god to forgive me?
>Have I missed a new function in 8.x.x? 

 sYS_CONTEXT('USERENV', 'OS_USER') ?

http://otn.oracle.com/docs/products/oracle8i/doc_library/817_doc/server.817/a85397/function.htm#88362

-- 
Andy Hassall (andy@andyh.org) icq(5747695) http://www.andyh.org
http://www.andyh.uklinux.net/space | disk usage analysis tool
