2012-03-05 Created By BaoXinjian
一、摘要
Oracle Metalink 提供一个诊断并发程式进程的脚本
This Script is made available for Diagnosing Common Problems Related to Concurrent Requests
该脚本的主要作用
1. There should never be more than 3-4K records
2. Please Run Purge Concurrent Requests /and or Manager Data if => 3K There should never be more than 3-4K records
3. Please Run Purge Concurrent Requests /and or Manager Data if => 3K If records found, Update fnd_concurrent_requests set phase_code='C' and status_code='E' where phase_code='T'
4. If records found, Update fnd_concurrent_requests set phase_code='C' where phase_code = 'P' to Purge Pending Requests
5. Limits the Number of Requests Run Simultaneously by each User
6. Setting this option to YES will enable the 'Submit a New Request' button
7. Enables you to automatically place requests on hold after submission
8. Determines access privs to report output/log files
9. The value for number of Report Copies Currently Set
10. Determines the Priority of a Request upon Submission
11. Identifies the domain within which all the incompatibilities between programs has to be resolved
12. Setting this option to YES will save the output from a concurrent request to a file.
二、分析
Step1. SQLPLUS调用该脚本
SQL> @REQCHECK.sql
Step2. 脚本自动产生Report Log在相应目录
[applvis@paleonode1 scripts]$ cat reqcheck.lst
Step3. 具体的Report
There should never be more than 3-4K records
COUNT(*)
----------
3514
Please Run Purge Concurrent Requests /and or Manager Data if => 3K
There should never be more than 3-4K records
COUNT(*)
----------
1221
Please Run Purge Concurrent Requests /and or Manager Data if => 3K
If records found, Update fnd_concurrent_requests set phase_code='C'
and status_code='E' where phase_code='T'
COUNT(*)
----------
0
If records found, Update fnd_concurrent_requests set phase_code='C'
where phase_code = 'P' to Purge Pending Requests
COUNT(*)
----------
2
Limits the Number of Requests Run Simultaneously by each User
no rows selected
Setting this option to YES will enable the 'Submit a New Request' button
no rows selected
Enables you to automatically place requests on hold after submission
PROFILE_OPTION_VALUE
--------------------------------------------------------------------------------
N
Determines access privs to report output/log files
PROFILE_OPTION_VALUE
--------------------------------------------------------------------------------
U
The value for number of Report Copies Currently Set
PROFILE_OPTION_VALUE
--------------------------------------------------------------------------------
0
Determines the Priority of a Request upon Submission
PROFILE_OPTION_VALUE
--------------------------------------------------------------------------------
50
Identifies the domain within which all the incompatibilities
between programs has to be resolved
no rows selected
Setting this option to YES will save the output from a concurrent
request to a file.
PROFILE_OPTION_VALUE
--------------------------------------------------------------------------------
Y
Setting this option to YES will force concurrent requests to run sequentially
in the order in which they were submitted.
PROFILE_OPTION_VALUE
--------------------------------------------------------------------------------
N
Set this option to YES to show request set stages in the concurrent
request screens.
no rows selected
Set this option to NO if you have multiple requests to submit and do not wish to
see the Request Summary form after each submission.
PROFILE_OPTION_VALUE
--------------------------------------------------------------------------------
N
Specifies the number of minutes that a client will wait for a given Transaction
Manager to become available before trying a different Transaction Manager.
PROFILE_OPTION_VALUE
--------------------------------------------------------------------------------
1
Step4. 具体的脚本REQCHECK.sql
REM #########################################################################
REM ## Purpose: Diagnostic Script for Concurrent Requests
REM ## Author: Brian Kerr
REM ## Email: brian.kerr@oracle.com
REM ## Filename: reqcheck.sql
REM ## Cert: 10.7, 11, 11.5, 12
REM ## Note:
REM ## Usage: sqlplus apps/ @reqcheck.sql
REM ## Output: reqcheck.lst
REM ## Notes:
REM ## a. The selects below run against system level only.
REM ## b. Include Responsibility & User level queries - Open.
REM ## c. '0 Rows Selected' represents that the Profile Option is Not Set.
REM ##
REM ## $Id: reqcheck.sql, v 1.2 2001/11/18 17:20:00 bkerr Exp $
REM #########################################################################
spool reqcheck.lst
prompt There should never be more than 3-4K records
select count(*) from fnd_concurrent_requests;
prompt Please Run Purge Concurrent Requests /and or Manager Data if => 3K
prompt There should never be more than 3-4K records
select count(*) from fnd_concurrent_processes;
prompt Please Run Purge Concurrent Requests /and or Manager Data if => 3K
prompt If records found, Update fnd_concurrent_requests set phase_code='C'
prompt and status_code='E' where phase_code='T'
select count(*) from fnd_concurrent_requests
where phase_code='T';
prompt If records found, Update fnd_concurrent_requests set phase_code='C'
prompt where phase_code = 'P' to Purge Pending Requests
select count(*) from fnd_concurrent_requests
where phase_code='P';
prompt Limits the Number of Requests Run Simultaneously by each User
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Active Request Limit';
prompt Setting this option to YES will enable the 'Submit a New Request' button
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Enable Request Submission in View Mode';
prompt Enables you to automatically place requests on hold after submission
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Hold Requests';
prompt Determines access privs to report output/log files
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Report Access Level';
prompt The value for number of Report Copies Currently Set
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Report Copies';
prompt Determines the Priority of a Request upon Submission
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Request Priority';
prompt Identifies the domain within which all the incompatibilities
prompt between programs has to be resolved
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Conflicts Domain';
prompt Setting this option to YES will save the output from a concurrent
prompt request to a file.
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Save Output';
prompt Setting this option to YES will force concurrent requests to run sequentially
prompt in the order in which they were submitted.
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Sequential Requests';
prompt Set this option to YES to show request set stages in the concurrent
prompt request screens.
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Show Requests Set Stages';
prompt Set this option to NO if you have multiple requests to submit and do not wish to
prompt see the Request Summary form after each submission.
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent: Show Requests Summary After Each Request Submission';
prompt Specifies the number of minutes that a client will wait for a given Transaction
prompt Manager to become available before trying a different Transaction Manager.
select c.profile_option_value
from fnd_profile_options a, fnd_profile_options_tl b, fnd_profile_option_values c
where a. profile_option_name = b.profile_option_name
and a.profile_option_id = c.profile_option_id
and c.level_id = 10001
and b.user_profile_option_name = 'Concurrent:Wait for Available TM';
spool off
Thanks and Regards
参考:Pan_Tian - http://blog.csdn.net/pan_tian/article/details/8634639
参考:Metalink - Diagnostic Script for Concurrent Requests (Doc ID 164978.1)
ERP技术讨论群: 288307890
技术交流,技术讨论,欢迎加入
Technology Blog Created By Oracle ERP - 鲍新建