CompareUserObjects with specified schemas to compare

Maxmix

Member³
Hi!

I am comparing objects, connected as USER1 to local db and remote db.
However, compared schemas have different name (user USER2 at local db vs target schema USER2 at remote db). One difference found is for table:

SQL:
--------------------------------------
--  Changed table paycal_x_zao_cre  --
--------------------------------------
-- Drop primary, unique and foreign key constraints
alter table PAYCAL_X_ZAO_CRE
  drop constraint UQ_XZC cascade;

During applying it gives me "ora-00942".

Script should include schema owner, like this:
--------------------------------------
-- Changed table paycal_x_zao_cre --
--------------------------------------
-- Drop primary, unique and foreign key constraints
alter table USER2.PAYCAL_X_ZAO_CRE
drop constraint UQ_XZC cascade;
 
Similar error occurred today with the check constraints (I am on 9.0.2.1623 now).

-- Create/Recreate check constraints
alter table INVENTORY
drop constraint CHK_INY_STATE_ENUM;
alter table TANGIBLES.INVENTORY
add constraint CHK_INY_STATE_ENUM
check (iny_state in ('EXTERNAL', 'CANDIDATE', 'REVISED','HAS_DEFECTS', 'READY'));

 
Back
Top