Search This Blog

Thursday, May 7, 2015

Script to find concurrent request id from known SID

select f.request_id, v.spid,s.sid, s.username,s.serial#, s.osuser, s.status
from gv$process v, gv$session s, applsys.fnd_concurrent_requests f
where 1=1
and s.paddr=v.addr
and f.oracle_process_id=v.spid
and trunc(f.request_date)=trunc(sysdate)
and sid=&SID

Thursday, April 30, 2015

Script to find any profile option in Oracle applications

SELECT fpo.profile_option_id, fpot.profile_option_name profile_short_name
, substr(fpot.user_profile_option_name,1,60) profile_name
, DECODE(fpov.level_id,10001,'site',10002,'Appl',10003,'Resp',10004,'User') profile_level
, substr(DECODE(fpov.level_id,10001,null, 10002,fa.application_short_name
,10003,fr.responsibility_name, 10004,fu.user_name),1,30) level_value
, fpov.profile_option_value profile_value
FROM fnd_profile_option_values fpov
, fnd_profile_options fpo
, fnd_profile_options_tl fpot
, fnd_application fa
, fnd_responsibility_tl fr
, fnd_user fu
WHERE (fpo.profile_option_name like nvl('X',fpo.profile_option_name) -- Replace X with the profile short name, ie 'PRINTER'
or fpot.user_profile_option_name like nvl('Y',fpot.user_profile_option_name)) -- Replace Y with profile user name, ie 'Printer%'
and fpo.profile_option_name=fpot.profile_option_name
and fpo.profile_option_id = fpov.profile_option_id
and fa.application_id(+)=fpov.level_value
and fr.responsibility_id(+)=fpov.level_value
and fu.user_id(+)=fpov.level_value;

Reference:
Script To List The Values Of A Profile Option At All Levels (Doc ID 803587.1)
How To Check If a Profile Option Is Set In Oracle Applications? (Doc ID 470102.1)
How To List E-Business Suite Profile Option Values For All Levels Using SQLPlus (Doc ID 201945.1)
How to Search all of the Profile Options for a Specific Value (Doc ID 282382.1)
How To Find All Users With A Particular Profile Option Set? (Doc ID 367926.1)

Saturday, April 25, 2015

Script to find responsibilities assigned for an user in EBS

Select b.user_name, c.responsibility_name, a.START_DATE, a.END_DATE
from fnd_user_resp_groups_direct a, fnd_user b, fnd_responsibility_tl c
where a.user_id = b.user_id
and a.responsibility_id = c.responsibility_id
and b.user_name in ('&USERNAME');

Script to get assigned responsibilities for a concurrent program

SELECT DISTINCT *
           FROM apps.fnd_responsibility_tl
          WHERE responsibility_id IN (
                   SELECT responsibility_id
                     FROM apps.fnd_responsibility_vl
                    WHERE request_group_id IN (
                             SELECT request_group_id
                               FROM apps.fnd_request_group_units
                              WHERE request_unit_id =
                                       (SELECT DISTINCT concurrent_program_id
                                                   FROM Apps.fnd_concurrent_programs_tl
                                                  WHERE user_concurrent_program_name like '%&Program Name%'))
                      AND end_date IS NULL)
 AND "LANGUAGE" LIKE 'US'
       ORDER BY responsibility_name;

Wednesday, April 15, 2015

Steps to configure printer in Oracle apps 11i/R12

Please follow the below Steps:

1. Setup the printer at the OS level
2. Add a valid entry in the hosts file (Printer Name and the IP Address), if ip address is resolved by DNS this step can be ignored
3. Login to System Administrator responsibility
4. Navigate to Install > Printer > Register
5. Define a new printer by entering the Printer Name
6. Save
7. Bounce the Concurrent Manager
8. Submit any standard concurrent request


References:
Step By Step Guide to Set Up a Printer in Oracle Applications (Doc ID 60936.1)
How to Implement Printing for Oracle Applications: Getting Started (Doc ID 269129.1)

Tuesday, October 21, 2014

ORA-00955: name is already used by an existing object & ORA-06512: at "SYS.UTL_RECOMP", line 662

Issue:

When I ran utlrp.sql to compile the INVALID objects in database, I see it error out due to

DOC>#
DECLARE
*
ERROR at line 1:
ORA-00955: name is already used by an existing object
ORA-06512: at "SYS.UTL_RECOMP", line 662
ORA-06512: at line 4

Cause:

Looks like known bug#9881143 in Oracle Database - Enterprise Edition - Version 10.2.0.1 to 10.2.0.5 [Release 10.2] where an index is left from a previous failed execution of utl_recomp.

SQL> /

OWNER                          SEGMENT_NAME                                  SEGMENT_TYPE
------------------------------ --------------------------------------------- ------------------
SYS                            UTL_RECOMP_COMP_IDX1                          INDEX


Solution: Drop the index utl_recomp_comp_idx1 left by utl_recomp and then rerun the package.



SQL> drop index UTL_RECOMP_COMP_IDX1;

Index dropped.


Compile script completed successfully:
SQL> @?/rdbms/admin/utlrp.sql

TIMESTAMP
----------------------------------------------------------------------------------------------------
COMP_TIMESTAMP UTLRP_BGN  2014-10-21 11:14:12

ERRORS DURING RECOMPILATION
---------------------------
                          0

PL/SQL procedure successfully completed.

Reference: Ora-955 Error Running Utl_Recomp.Recomp_Serial (Doc ID 1274504.1)

Friday, September 12, 2014

APP-FND-01926: The custom event WHEN-LOGON-CHANGED raised unhandled exception: ORA-06508: PL/SQL: could not find program unit being called



This issue has been observed under the following circumstances:

CUSTOM.plx file are of different date than the conversion date (last compilation date), the likeky reason for this is that CUSTOM.pll has not been properly compiled.
For example:
-rwxr-xr-x    1 oradev   dba           24576 Aug 24 2009  CUSTOM.pll
-rwxr-xr-x    1 oradev   dba           20480 Mar 31 12:36 CUSTOM.plx




To implement the solution, please do the following:
1. Take a backup of both files CUSTOM.PLL and CUSTOM.PLX
2. Get a working copy of the custom.pll file.
3. Compile the custom.pll using f60gen under the environment which creates the file custom.plx, where the last access date shows the current date.
f60gen \
module=$AU_TOP/resource/CUSTOM.pll \
userid=APPS/xxx \
output_file=$AU_TOP/resource/CUSTOM.plx \
module_type=library batch=yes compile_all=special
4. The $FORMS60_PATH needs to be in sync with the value set for the s_f60path variable in the Context.xml file.
i.e  >/oracle/apps/test10appl/au/11.5.0/resource:/oracle/apps/test10appl/au/11.5.0/resource/stub</FORMS60_PATH>

5. Run Autoconfig to instantiate the changes.

Ref:11i: "APP-FND-01926: The custom event WHEN-LOGON-CHANGED raised unhandled exception" Error When Attempting to Launch Forms (Doc ID 1080160.1)

Transportable tablespace refresh

  1.check tablespace for the user which need to refresh -------------------------------------------------------------------  SQL> select ...