Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

how would i compare if two indexes are identical?

Erhan_torontoJul 24 2013 — edited Jul 31 2013

I like to compare if two indexes from both users are identical. Is there any way to to that. I need similer to below query:

select CASE (2*(select count(*) from (select * from XPKTBL_A INTERSECT select * from XPKTBL_A )) - (select count(*) from XPKTBL_A ) - (select count(*) from XPKTBL_A )) WHEN 0 THEN 'Indexes are identical' ELSE 'Indexes are different' END "Result" from  DUAL;

UserA:

create table TBL_A (       FIELD_A1 number not null,

FIELD_A2 varchar2(50),

FIELD_A3 date,

FIELD_A4 number(5,2) default 0,

FIELD_A5 varchar2(10) not null

                                );

                                create unique index XPKTBL_A on TBL_A (FIELD_A1);

UserB:

create table TBL_A (       FIELD_A1 number not null,

FIELD_A2 varchar2(20),

FIELD_A4 number(5,2) not null,

FIELD_A5 varchar2(10),

FIELD_A6 number(2) not null

                                );

                                create unique index XPKTBL_A on TBL_A (FIELD_A1, FIELD_A6);

This post has been answered by Erhan_toronto on Jul 30 2013
Jump to Answer

Comments

AndrewSayer

Nisarg Oza wrote:

Hello ,

Recently I have upgraded one of my database from 9i to 12c.

I'm trying to connect oracle Oracle9i Release 9.2.0.4.0 - Production from 12c Release 12.1.0.1.0 - 64bit ,but I got message

ORA-03134: Connections to this server version are no longer supported

I can connect 9i to 12c by setting parameter in sqlnet.ora, SQLNET.ALLOWED_LOGON_VERSION=8 , but I cannot connect 12c to 9i.

Any solution for 12c to 9i connection or any alternate solution will also appreciable.

Thanks ,

Nisarg,

Why do you need to?


You could be using the 12c client to connect to your 12c database.

PKR

Hi

The SQLNET.ALLOWED_LOGON_VERSION parameter is deprecated in Oracle Database 12c.It has been replaced with two new Oracle Net Services parameters are

--for database

SQLNET.ALLOWED_LOGON_VERSION_SERVER = n

--Client

SQLNET.ALLOWED_LOGON_VERSION_CLIENT = n

try with 'n' value 11 or 12

unknown-7404

Recently I have upgraded one of my database from 9i to 12c.

Great!

Any solution for 12c to 9i connection or any alternate solution will also appreciable.

Now upgrade the other ones and your problem goes away.

Or use version appropriate client software to connect to 9i. But forget about direct 12c to 9i db links or other connectivity. As the exception says that isn't supported.

Oratig-Oracle

I suggest you to check Doc ID 207303.1 to know the Client / Server Interoperability Support

Oratig-Oracle

12.c client cannot connect to 9i database

Nisarg Oza

I have set both 11 and 12 in SQLNET.ALLOWED_LOGON_VERSION_SERVER,  but still I cannot connect 12c to 9i.

unknown-7404

I have set both 11 and 12 in SQLNET.ALLOWED_LOGON_VERSION_SERVER, but still I cannot connect 12c to 9i.

Correct - and you have already been told that several times.

Oratig-Oracle

You are trying to do something which oracle already explained in the document that it will not work..

if you make some changed and if you bring that as working, still it is not supported one

1 - 8
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Aug 28 2013
Added on Jul 24 2013
25 comments
1,926 views