EM でレポートを作成していますが、ここで何かを把握する必要があります
私が作成したこのクエリがあります:
SELECT
*
FROM
(
SELECT DISTINCT
patch.host as "PHost",
patch.home_location as "PDirectory",
patch.home_name as "PHome",
MAX(patch.INSTALLATION_TIME) as "Patched (Date)",
MAX(patch.PATCH_RELEASE) as "PVersion",
listagg(patch,',') WITHIN GROUP (ORDER BY patch) "Patches"
FROM
mgmt$applied_patches patch
GROUP BY patch.host, patch.home_location,patch.home_name
ORDER BY patch.host, patch.home_location
) "PCH",
(
SELECT DISTINCT
T1.PROPERTY_VALUE as "MHost",
T2.PROPERTY_VALUE as "MDirectory",
T3.PROPERTY_VALUE as "MVersion",
count(T4.PROPERTY_VALUE) as "Count of SID",
listagg(T4.PROPERTY_VALUE,',') WITHIN GROUP (ORDER BY T4.PROPERTY_VALUE) as "SID"
FROM
MGMT$TARGET_PROPERTIES T1,
MGMT$TARGET_PROPERTIES T2,
MGMT$TARGET_PROPERTIES T3,
MGMT$TARGET_PROPERTIES T4
WHERE
T1.TARGET_GUID = T2.TARGET_GUID
and T1.TARGET_GUID = T3.TARGET_GUID
and T1.TARGET_GUID = T4.TARGET_GUID
and T1.PROPERTY_NAME = 'MachineName'
and T2.PROPERTY_NAME = 'OracleHome'
and T3.PROPERTY_NAME = 'Version'
and T4.PROPERTY_NAME = 'SID'
GROUP BY T1.PROPERTY_VALUE, T2.PROPERTY_VALUE, T3.PROPERTY_VALUE
) "MGM"
WHERE
PDirectory = MDirectory
エラー ORA-00904 が表示されます: "MDIRECTORY":....
いろいろ組み合わせてみました!(PCH.PDirectory = MGM.MDirectory, ......) 何も機能しません
乾杯