• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1086
  • Last Modified:

SQL for comparing OLTP vs OLAP -(Source-OLTP) and Target-OLAP

I am trying to write a SQL query to compare two databases OLTP and OLAP to get the table counts eg:
we have table name W_ACT in OLAP database where count is 2500, we need to see what is the count for same table in OLTP(S_ACT).we have a long list of table counts I was wondering if some one could help me in genrating those counts all at once.

Thanks
Mein
0
MEINKIYAKAROON
Asked:
MEINKIYAKAROON
1 Solution
 
dbmullenCommented:
analyze the tables in both databases and query the catalog


insert into some_table
select
  (select instance_name from v$instance) db_name,
table_name, num_rows, sysdate from dba_tables@oltp
;
commit;

insert into some_table
select
  (select instance_name from v$instance) db_name,
table_name, num_rows, sysdate from dba_tables@olap
;
commit;


0

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

Tackle projects and never again get stuck behind a technical roadblock.
Join Now