EM 12c: Enterprise Manager 12c Cloud Control Shows the Target Database Name as the DB_UNIQUE_NAME rather than the DB_NAME (Doc ID 2214379.1)

Last updated on MAY 30, 2017

Applies to:

Enterprise Manager for Oracle Database - Version 12.1.0.4.0 and later
Information in this document applies to any platform.

Symptoms

If a target database has a DB_UNIQUE_NAME parameter defined, Enterprise Manager (EM) Cloud Control will display its database name with this value, instead of the value for the DB_NAME parameter.

This query derives the display name for EM Cloud Control:

SELECT d.database_name "DBName",
  i.instance_name "InstanceName",
  TO_CHAR(i.startup_time, f.time_format) "StartTime",
  f.time_format "TimeFormat",
  i.version "Version",
  p.value "TimedStatistics",
  r.open_mode "OpenMode",
  i.instance_number "RACInstNum"
FROM (select * from (SELECT name, value database_name
  FROM v$parameter
  WHERE (name = 'db_unique_name'
  OR name = 'db_name')
  AND value IS NOT NULL
  ORDER BY name DESC)
  where rownum = 1 ) d,
  v$instance i,
  v$parameter p,
  v$database r,
  (SELECT 'dd-mon-yyyy HH24:MI:SS' time_format
  FROM dual) f
WHERE p.name = 'timed_statistics';

Changes

 

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms