手動で作成したスプレッドシートを SQL レポートに変換する必要があります。レポートは、Oracle Forms (BI Suite アプリの 1 つ) を介して生成されます。
「リクエスト番号」で識別される、多くのチケットが届く受信ボックスがあります。
各リクエスト番号は、システム内のヘルプ デスク チケットです。そのスプレッドシートのスクリーンショットを次に示します。
列の完全なリスト (説明付き) :
Request No.
Modules
Submitted ( the request being submitted , a timestamp )
Supervisor ( the request being approved , by supervisor )
Average Supervisor Approval Duration
Responsibility
Average Resp. Approval Duration
Training (the request being approved for completing training)
Average Training Approval Duration -
Configuration - depending on whether its PRISM or iProcurement
Average Config. Approval Duration
Approved
Total Overall Duration
Security
Average Security Approval Duration
SOD
Avg SOD Approval Duration
私がやろうとしているのは、SQL スクリプトを使用して、その一部またはすべてを生成することです。
私の問題の 1 つは、.. 特定の「リクエスト番号」に対して、データベース内に冗長で競合するデータが頻繁に取得されることです。
以下は、これまでの私のクエリです。
SELECT hur.reg_request_id AS "Request No",
RESPONSIBILITY_NAME AS "Module",
to_char(hur.creation_date, 'DD-Mon-YYYY HH24:MI:SS') AS "Submitted" ,
to_char(hur.last_update_date, 'DD-Mon-YYYY HH24:MI:SS') AS "Supervisor" ,
ROUND((hur.last_update_date - hur.creation_date), 3 ) ||
' days' AS "Avg Supervisor Appr Duration" ,
/* hura.creation_date AS "Responsibility" */,
NULL AS "Avg Resp Appr Duration", NULL AS "Training",
NULL AS "Avg Training Appr Duration" ,
hur.LAST_UPDATE_DATE AS "Security",
NULL AS "Avg Security Appr Duration",
NULL AS "SOD",
NULL AS "Average SOD Approval Duration" ,
NULL AS "Configuration",
NULL AS "Avg Config Appr Duration",
hurr.last_update_date AS "Approved",
ROUND( hurr.last_update_date - hur.creation_date, 2 )
AS "Total Overall Duration",
NULL AS "Notes"
FROM HHS_UMX_REG_SERVICES hur
JOIN fnd_responsibility_vl frt
ON (hur.responsibility_id = frt.responsibility_id and
hur.responsibility_application_id = frt.application_id)
JOIN
hhs_umx_reg_requests hurr ON
(hurr.reg_request_id = hur.reg_request_id )
/* JOIN hhs_umx_resp_activity hura */
left outer JOIN
hhs_umx_resp_activity
hura ON (hur.reg_request_id = hura.reg_request_id )--ADD ON
WHERE EXISTS (
SELECT NULL FROM hhs_umx_resp_activity hura
WHERE hura.created_by = hur.created_by
AND
hura.creation_date > hur.creation_date)
AND hur.reg_request_id IN
('263428', '263458', '263473',
'264717', '263402', '263404',
'262671', '263229', '263268')
ORDER BY hur.reg_request_id ASC
スキーマは次のとおりです。
HHS_UMX_RESP_ACTIVITY
HHS_UMX_REG_SERVICES
fnd_responsibility_vl
**hhs_umx_reg_requests **
ありがとう