Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: Pl/SQL question
Sonja,
Instance is easy enough. Either grant the person SELECT access to the V_$INSTANCE view under the SYS account, or create another view owned by the DBA that returns the same information.
By schema, do you mean the schema where the procedure exists, or of the person executing the procedure?
If it's the person executing the procedure, you can easily return the USER value (select user from dual). If it's the schema where the procedure exists, then you can (select distinct owner from all_source where name='procedure_name'). Of course, you will need to grant SELECT on ALL_SOURCE to the user where the procedure exists from the sys account for this to work.
hope this helps.
Tom Mercadante
Oracle Certified Professional
-----Original Message-----
Sent: Monday, June 25, 2001 8:45 AM
To: Multiple recipients of list ORACLE-L
List hi!
Oracle 8.1.7 EE on AIX.
One of our developers wrote a procedure. Inside that procedure he wants to
know instance and schema, while executing that procedure.
Do you have any suggestions?
TIA,
Sonja
-- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: =?iso-8859-2?Q?Sonja_=A9ehovi=E6?= INET: sonja.sehovic_at_pbz.hr Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051 San Diego, California -- Public Internet access / Mailing Lists -------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-LReceived on Mon Jun 25 2001 - 07:19:34 CDT
(or the name of mailing list you want to be removed from). You may
also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Mercadante, Thomas F INET: NDATFM_at_labor.state.ny.us Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051 San Diego, California -- Public Internet access / Mailing Lists -------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from). You may
also send the HELP command for other information (like subscribing).
![]() |
![]() |