Making Custom Reports Oracle Apps Compliant
Posted May 31, 2012on:
To Make sure that the report is Oracle Applications compliant when using the views which have security profile instead of using base tables, we should note the below few things when we run it on our local machine (TOAD, Report Builder) have any ouput but when after registering in Oracle Application, it doesn’t show any output although we have put the mo_global or SRW.
- SRW.USER_EXIT(‘FND SRWINIT’)
The SRW.USER_EXIT(‘FND SRWINIT’) is used in AOL report and is used to setup your user profile. If you are in a muilti_org environment, this ensures that your report display data from the user’s organization and this is set in Before Report Trigger. You call SRW.USER_EXIT in after report trigger to make sure that all the memory allocated for AOL is freed up.In eBusiness Suite R12 (release 12), the SRW.USER_EXIT(‘FND SRWINIT’) call must be made in the after parameter formtrigger, and not in the before report trigger. If this is not done, your Oracle Reports will not output any data from multi-org striped synonyms or views such as RA_CUSTOMER_TRX, OE_ORDER_HEADERS, PO_VENDORS, etc.
We can use srw.user_exit(‘FND SRWINIT’) in After Parameter Report or Before Report Trigger, Report will works fine. You must define P_CONC_REQUEST_ID Paremeter.
In case of R12, Its necessary to add ‘SRW.USER_EXIT(‘FND SRWINIT’)’ in after parameter form, otherwise you will get output and sometimes not.
We had several custom reports that worked fine before, when put the MO_GLOBAL.SET_POLICY_CONTEXT(‘S’,:p_org_id) at before report trigger. But sometimes we didn’t get any output so we made the change from before report trigger to the before parameter form trigger and then the reports work fine again.