Solved

dbms_utility.active_instances

Posted on 2001-07-16
3
606 Views
Last Modified: 2008-01-09
I am trying to determine the instance name using dbms_utility.  I get following error:

PLS-00306: wrong number or types of arguments in call to 'ACTIVE_INSTANCES'

Any suggestions. Code snippet below:


TYPE instance_record is RECORD
(
       inst_number number,
      inst_name   varchar2(60)
);
     

TYPE instance_table is TABLE OF instance_record INDEX BY BINARY_INTEGER;

inst_tab instance_table;
inst_count number;

BEGIN      
 DBMS_UTILITY.ACTIVE_INSTANCES(inst_tab, inst_count);
END;
0
Comment
Question by:curtjenk
  • 2
3 Comments
 
LVL 5

Expert Comment

by:ser6398
Comment Utility
try declaring your variable as follows:

inst_tab   DBMS_UTILITY.instance_table;



0
 
LVL 3

Expert Comment

by:UsamaMunir
Comment Utility
SQL> declare
  2  inst_table DBMS_UTILITY.INSTANCE_TABLE;
  3  INST_NUM NUMBER;
  4  BEGIN
  5  DBMS_UTILITY.ACTIVE_INSTANCES(INST_TABLE,INST_NUM);
  6  END;
  7  /

PL/SQL procedure successfully completed.

I HOPE IT HELPS

Regards
Usama Munir
0
 
LVL 5

Accepted Solution

by:
ser6398 earned 25 total points
Comment Utility
DECLARE

inst_tab     DBMS_UTILITY.instance_table;
inst_count   number;

BEGIN      
  DBMS_UTILITY.ACTIVE_INSTANCES(inst_tab, inst_count);
END;
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Have you ever had to make fundamental changes to a table in Oracle, but haven't been able to get any downtime?  I'm talking things like: * Dropping columns * Shrinking allocated space * Removing chained blocks and restoring the PCTFREE * Re-or…
Configuring and using Oracle Database Gateway for ODBC Introduction First, a brief summary of what a Database Gateway is.  A Gateway is a set of driver agents and configurations that allow an Oracle database to communicate with other platforms…
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
This video shows setup options and the basic steps and syntax for duplicating (cloning) a database from one instance to another. Examples are given for duplicating to the same machine and to different machines

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now