Quantum data in EM repository?

  • From: "Herring, David" <HerringD@xxxxxxx>
  • To: "oracle-l@xxxxxxxxxxxxx" <oracle-l@xxxxxxxxxxxxx>
  • Date: Thu, 24 Sep 2015 20:11:02 +0000

Folks,

I've got a strange situation in querying data in MGMT$TARGET_ASSOCIATIONS in a
12.1.0.2 EM repository. We have 7 different EM repositories and I'm trying to
pull data from all for a report, "Oracle Real Application Cluster (RAC)
Database Topology". It's a great EM report but obviously it's only local. I
thought it'd be great for management if I copied that report, created table
versions of various MGMT$* views, then had a weekly job to pull from each
repository into these C_MGMT$* tables.

This all works EXCEPT a number of rows in MGMT$TARGET_ASSOCIATIONS are playing
hide-and-seek. Within the report above, chart "Aggregated RAC Databases Nodes
Distribution" uses a cursor against this view. When I noticed the
consolidated data didn't look correct I checked one of the 12c repositories and
ran the following as SYSMAN:


SELECT COUNT(*) FROM sysman.mgmt$target_associations

WHERE SUBSTR(source_target_name, 1, 8) IN (<various database names>)

AND assoc_def_name = 'contains';


COUNT(*)

------------------

92

SELECT COUNT(*) FROM sysman.mgmt$target_associations
WHERE assoc_def_name = 'contains';

COUNT(*)
------------------
0

The 2 cursors use different plans which might hint at a wrong results issue.
Since this cursor involves views of views ... I checked the following:

SELECT /*+ NO_QUERY_TRANSFORMATION */ COUNT(*) FROM
sysman.mgmt$target_associations ta
WHERE assoc_def_name = 'contains';

COUNT(*)
------------------
2506

I'm not missing something incredibly obvious with EM data, am I?

Regards,

Dave

Other related posts: