Tuesday, November 26, 2013

Enabling Trace for reports in R12

This blog explains how to enable a trace for concurrent programs that run rdf reports to generate output.


Enabling Trace for reports in R12

Enable trace, in the report, so the command used to submit it will appear in the log file.
Using the System Administrator responsibility navigate to the Define Concurrent Program Screen and query the report. Check the box next to Enable Trace.
Submit the report from the Concurrent Manager and view the log file for the NLS_LANG Parameter and the command used to run the report.

Example:
A.Submit Concurrent program from "Submit New Request"
B.When the request completes click on the View Log button.
Copy the lines between -- Start of Reports Command --
                              and -- End of Reports Command --


Arguments
------------
p_mag_assign_action_id='882414262'
------------


 -- Start of Reports Command --
/u01/oracle/test/inst/apps/test_host/ora/10.1.2/bin/appsrwrun.sh
P_CONC_REQUEST_ID=1340141
p_mag_assign_action_id='882414262'
report=/u01/oracle/test/apps/apps_st/appl/pip/12.0.0/reports/US/TEST.rdf
batch=yes
destype=file
desname=/u01/oracle/test/inst/apps/TEST_host/logs/appl/conc/out/o1340141.out
desformat=XML
 -- End of Reports Command --


Verify the Forms CATCHTERM variable and be sure it is set to 0. If the CATCHTERM variable is not set to 0 (zero) a core file will not be created.
Example:
echo $FORMS_CATCHTERM
export FORMS60_CATCHTERM=0

Verify your DISPLAY setting: echo $DISPLAY
If DISPLAY is not set: export DISPLAY=

Convert to REP to prevent any compilation issue as below
 REP-1247: The report contains uncompiled PL/SQL.
 $ORACLE_HOME/bin/rwconverter.sh userid=apps/password@apps source=/u01/oracle/test/apps/apps_st/appl/pip/12.0.0/reports/US/HBPY_PDF_PAY_SLIP.rdf stype=RDFFILE dtype=RDFFILE compile_all=yes batch=yes

Run the report from the command line with TRACE Option as follows:

$INST_TOP/ora/10.1.2/bin/appsrwrun.sh userid=apps/appsnft@hrcmnft p_mag_assign_action_id='882414262' report=/home/oracle/onlinepdf.rep batch=yes destype=file desname=/home/hrcmpll/payslip.out desformat=XML traceopts=trace_all tracefile=/home/hrcmpll/payslip.trc tracemode=trace_replace

Here default is trace_all (Log all possible trace information in the trace file)

TRACEFILE= Any valid file name including the full path to the file.

TRACEMODE= TRACE_APPEND Adds the new information to the end of the file and TRACE_REPLACE Overwrites the file

No comments:

Post a Comment

Your Comments on blog are strongly welcomed..