Friday, August 23, 2013

Error while order import in R12 Unable to determine the Country code for the Location id: XXXXXX and Location type: BILL_TO

Reason for the issue. 

  If a new country added in the FND_TERRITORIES_TL and FND_TERRITORIES and the same data is not available in HZ_GEOGRAPHIES.

How to resolve the issue
   Login to unix box and go the below top
$AR_TOP/patch/115/sql

Then download the below file.
ARHGEFTR.sql

and execute it from apps schema. 

Wednesday, August 21, 2013

Attaching the concurrent program to the request group from back end script

BEGIN
   fnd_program.add_to_group (
      'XXFINTSTCPDB', -- Concurrent Program Short Name
      'XXFIN', -- Application Short Name
      'All Reports', -- Report Group Name
      'SQLAP'-- Report Group Application
   );
   COMMIT;
END;

Tuesday, August 20, 2013

How to see the concurrent program Execution Methods from back end

SELECT MEANING "Execution Method"
FROM fnd_lookup_values
WHERE lookup_type = 'CP_EXECUTION_METHOD_CODE'
AND enabled_flag  = 'Y'

How to see information about environment name and value from back end

This table stores information about environment name and value 

select * from FND_ENV_CONTEXT

How to check the concurrent managers from back end

select * from FND_CONCURRENT_QUEUES_VL

Concurrent Request Life Cycle


Wednesday, August 7, 2013

error stack vs dbms_output.put_line

DBMS_UTILITY.FORMAT_CALL_STACK  is used to display the stack information of a procedure or a function. 

PL/SQL offers a powerful and flexible exception architecture. Of course, there is always room for improvement, and in Oracle Database 10g, exception handling takes a big step forward with the introduction of the DBMS_UTILITY.FORMAT_ERROR_BACKTRACE function. 

Who Raised That Exception?

When an exception is raised, one of the most important pieces of information a programmer would like to uncover is the line of code that raised the exception. Prior to Oracle Database 10g, one could obtain this information only by allowing the exception to go unhandled.
 example :
  CREATE OR REPLACE PROCEDURE proc1 IS
BEGIN
   DBMS_OUTPUT.put_line ('running proc1');
   RAISE NO_DATA_FOUND;
END;
/
CREATE OR REPLACE PROCEDURE proc2 IS
BEGIN
   DBMS_OUTPUT.put_line ('calling proc1');
   proc1;  
END;
/
CREATE OR REPLACE PROCEDURE proc3 IS
BEGIN
   DBMS_OUTPUT.put_line ('calling proc2');
   proc2;
END;
/

CREATE OR REPLACE PROCEDURE proc3
IS
BEGIN
  DBMS_OUTPUT.put_line ('calling proc2');
  proc2;
EXCEPTION
  WHEN OTHERS THEN
      DBMS_OUTPUT.put_line (DBMS_UTILITY.FORMAT_ERROR_STACK);
END;
/
SQL> SET SERVEROUTPUT ON
SQL> exec proc3
calling proc2
calling proc1
running proc1
ORA-01403: no data found



DBMS_OUTPUT.PUT_LINE  is used to display the information on the screen. This also we can use it for debugging purpose. Only thing we have to use it in all the places of the procedure or function. 

Some of the useful profiles in Order Management

OM: Show Line Details
ONT_SHOW_LINE_DETAILS
This profile option determines whether the line details of a model are displayed in the Sales Orders window. You can also toggle the display of line details using the Tools menu from the Sales Orders window.

OM: Sales Order Form: Refresh Method (Query Coordination)
OM_UI_REFRESH_METHOD
This profile option determines whether the screen is refreshed after every save. There are four options available:
• Automatic Refresh with Repositioning of Cursor: When the profile is set to this option then screen is refreshed and also the cursor is repositioned to the original line from which the save operation was performed.
• Automatic Refresh Without Repositioning Of Cursor: When the profile is set to this option then screen is refreshed and the cursor is always positioned on the first line.
• Manual: With this option, users have to explicitly requery to see the latest changes. User are also not prompted with a message.
• Askme: A dialog box is prompted for the users to decide whether they want to refresh the screen to see the new data. If the user selects yes, then the screen is refreshed. If the user selects No then screen is not refreshed.
OM: Prevent Booking for Line Generic Holds
ONT_PREVENT_BOOKING
If a generic hold has been applied the transaction will fail booking.
OM: Enforce Check For Duplicate Purchase Order
ONT_ENFORCE_DUP_PO
When this profile option is set to Yes or is blank, a check will be made to verify if the entered PO number is duplicate or not. It will display a warning if a duplicate number is found. When the profile option is set to No, a check to verify for duplicate PO number will not be carried out.




OM: E-Mail Required on New Customers
ONT_MANDATE_CUSTOMER_EMAIL
This profile option determines whether the field E-mail address is required for any customer or customer contact you define within Order Management. Select from:
• Yes: E-mail address is required, for both the customer and customer contact, when defining or updating a customer or customer contact.
• No or NULL (the default): E-mail address is not required when defining or updating either a customer or customer contact.

OM: Display Actions Button vs. Poplist

Controls whether the traditional button for Actions or a pop list will be used to display available Actions. Valid values are: Button and Pop list. The default value will be Button for backward compatibility.

Monday, August 5, 2013

How to set the User-Level Multiple Organizations in Oracle apps R12

The MO: Security Profile controls the list of operating units a user with a specific
responsibility can access and the MO: Default Operating Unit controls the default
operating unit that defaults in all pages that display the operating unit field. Users can
further tailor the number of operating units they want to work with and specify a
different default operating unit by using the Multi-Org Preferences page. This allows
users to have complete control over their work environment to help them process data
more efficiently.
This page can be accessed using the menu function called User Preferences.
Note: If you do not see the User Preferences function from your application, inform
your system administrator to add the user preferences function called FNDMOPREFS
to your product's submenu. The default operating unit set on the Multi-Org Preferences
page will be saved to the MO: Default Operating Unit profile option at the user level.
To define a user preference:
1. Open the Multi-Org Preferences page.
The following information will appear at the header level:
• User Name: The user name of the user
• Responsibility Name: The name of the responsibility that accessed the page.
• Security Profile: The name of the security profile assigned to the MO: Security
Profile for the responsibility/user.
2. You can specify a default operating unit. The list of operating units will be limited
Setup and Implementation 2-25
to those assigned to the Security Profile.
3. You can select one or more operating units and then set them as preferred operating
units by clicking the Set as Preferred button.