Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> Re: Using database links in a proc
hi ,
Use dynamic method to run this type of program.
Regards,
Raman
From: Zabair.Ahmed_at_natwest.com on 23/05/2000 16:47 GMT
Please respond to ORACLE-L_at_fatcity.com
To: ORACLE-L_at_fatcity.com
cc:
Subject: Using database links in a proc
I've got the following piece of pl/sql
create or replace procedure objectfit(s_dblink IN VARCHAR2) as
dblink VARCHAR2(30);
CURSOR objectfit_cur IS
select s.owner, s.segment_name, s.segment_type, s.next_extent, s.extents, s.pct_increase from dba_segments_at_dblink s, dba_free_space_at_dblink f where s.tablespace_name = f.tablespace_name and s.segment_type in ('TABLE','INDEX') having s.next_extent > (0.5 * max(f.bytes)) group by f.tablespace_name, s.owner, s.segment_name, s.segment_type, s.next_extent;
BEGIN dblink := s_dblink;
etc
I want to pass the database link (dblink) as a parameter in the procedure
(s_dblink),
my question is can i do this if so how.
When i run the above cursor i get an error message saying it can't find the
database link, dblink (obvious).
Any ideas!!!!
TIA Regards
Zabair
-- Author: INET: Zabair.Ahmed_at_natwest.com 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 Wed May 24 2000 - 02:20:03 CDT
(or the name of mailing list you want to be removed from). You may
![]() |
![]() |