Tuesday, March 26, 2013

FND Tables in Oracle Application


Here there are few key FND tables that we use in our AOL queries.

FND_APPLICATION:
Stores applications registered with Oracle Application Object Library.
FND_APPLICATION_TL:
 Stores translated information about all the applications registered with Oracle Application Object Library.
FND_APP_SERVERS:
 This table will track the servers used by the E-Business Suite system.
FND_ATTACHED_DOCUMENTS:
 Stores information relating a document to an application entity.
FND_CONCURRENT_PROCESSES:
 Stores information about concurrent managers.
FND_CONCURRENT_PROCESSORS:
 Stores information about immediate (subroutine) concurrent program libraries.
FND_CONCURRENT_PROGRAMS:
 Stores information about concurrent programs. Each row includes a name and description of the concurrent program.
FND_CONCURRENT_PROGRAMS_TL:
 Stores translated information about concurrent programs in each of the installed languages.
FND_CONCURRENT_QUEUES:
 Stores information about concurrent managers.
FND_CONCURRENT_QUEUE_SIZE:
 Stores information about the number of requests a concurrent manager can process at once, according to its work shift.
FND_CONCURRENT_REQUESTS:
 Stores information about individual concurrent requests.
FND_CONCURRENT_REQUEST_CLASS:
 Stores information about concurrent request types.
FND_CONC_REQ_OUTPUTS:
 This table stores output files created by Concurrent Request.
FND_CURRENCIES:
 Stores information about currencies.
FND_DATABASES:
 It tracks the databases employed by the eBusiness suite. This table stores information about the database that is notinstance specific.
FND_DATABASE_INSTANCES:
 Stores instance specific information. Every database has one or more instance.
FND_DESCRIPTIVE_FLEXS:
 Stores setup information about descriptive flexfields.
FND_DESCRIPTIVE_FLEXS_TL:
 Stores translated setup information about descriptive flexfields.
FND_DOCUMENTS:
     Stores language-independent information about a document.
FND_EXECUTABLES:
 Stores information about concurrent program executables.
FND_FLEX_VALUES:
 Stores valid values for key and descriptive flexfield segments.
FND_FLEX_VALUE_SETS:
 Stores information about the value sets used by both key and descriptive flexfields.
FND_LANGUAGES:
 Stores information regarding languages and dialects.
FND_MENUS:
 It lists the menus that appear in the Navigate Window, as determined by the System Administrator when definingresponsibilities for function security.
FND_MENUS_TL:
 Stores translated information about the menus in FND_MENUS.
FND_MENU_ENTRIES:
 Stores information about individual entries in the menus in FND_MENUS.
FND_PROFILE_OPTIONS:
 Stores information about user profile options.
FND_REQUEST_GROUPS:
 Stores information about report security groups.
FND_REQUEST_SETS:
 Stores information about report sets.
FND_RESPONSIBILITY:
 Stores information about responsibilities. Each row includes the name and description of the responsibility, theapplication it belongs to, and values that identify the main menu, and the first form that it uses.
FND_RESPONSIBILITY_TL:
 Stores translated information about responsibilities.
FND_RESP_FUNCTIONS:
 Stores security exclusion rules for function security menus. Security exclusion rules are lists of functions and menusinaccessible to a particular responsibility.
FND_SECURITY_GROUPS:
 Stores information about security groups used to partition data in a Service Bureau architecture.
FND_SEQUENCES:
 Stores information about the registered sequences in your applications.
FND_TABLES:
 Stores information about the registered tables in your applications.
FND_TERRITORIES:
 Stores information for countries, alternatively known as territories.
FND_USER:
 Stores information about application users.
FND_VIEWS:
 Stores information about the registered views in your applications

WHO COLUMNS in Oracle Apps

WHO columns are used to track the information updated or inserted by the users against the tables. FND_STANDARD package is used for this purpose. FND_STANDARD.SET_WHO Procedure is used to update the WHO columns in aTable when a DML operation s (i.e. INSERT, UPDATE) performed.1) Created by2) Creation date3) Last _updated_by4) last_update_date5) last_update_login

  •  Use fnd_profile.VALUE (‘USER_ID’) for retrieving the user_id   which will be used by created_by column.
  •  Creation date and last_update_date will be normally SYSDATE.
  •  last_updated_by is same as created_by.
  •  Use USERENV (‘SESSIONID’) for getting the last_update_login id



Monday, March 18, 2013

Sales Order Line Status Flow and Meaning


Below are some of the different statuses of Sales Order Line with brief explanation

OM = Order Management Sales order form
SE = Shipping Transactions or execution form

1) Entered (OM): Order is saved but not booked

2) Booked (OM): Order is Booked.

3) Awaiting Shipping (OM): Order is booked but lines are not yet picked.
Navigating to Shipping Execution, the delivery line status flow is:

4) Not Ready to Release (SE): A delivery line may be in this status when it is interfaced manually into Shipping, is not scheduled and has no reservations. When lines are imported automatically from Order Management this status is not used

5) Released to Warehouse (SE): Pick Release has started but not yet completed. One of the reason could be allocation have not been pick confirmed. The Pick Release process creates a Move Order Header & Mover Order Line in Inventory. This is a common status for users that perform a two-step pick release process. This status indicates that inventory allocation has occurred however pick conformation has not yet taken place.

6) Ready to Release (SE): Order Line is booked and passed to shipping execution. The line is now eligible to pick Release.

7) Backordered(SE): The status of Backorderd is assigned to a line under the following circumstances.

·         The Pick Release process attempted to allocate inventory to the line and all or a partial quantity of the item was not available. In this case the system automatically backorders the discrepant quantity.
·         At Ship confirm the user enters a shipped quantity for an item that is less than the original requested quantity.
·         The user manually Backorders the entire delivery.
8) Shipped (SE): The delivery line is shipped confirmed.

9) Confirmed (SE): The delivery line is shipped or backordered and the trip stops are open.

10) Picked (OM): Pick release is complete, both allocations and pick confirm

11) Picked Partial (OM): This status occurs when a delivery line is not allocated the full quantity during Pick Release and Ship Confirm has not occurred

12) Interfaced (SE): The delivery line is shipped and Inventory interface concurrent process is complete.

13) Awaiting Fulfillment (OM): When fulfillment set is used, Not all shippable lines in a fulfillment set or a configuration are fulfilled

14) Fulfilled (OM): All lines in a fulfillment set are fulfilled.

15) Interfaced to Receivables (OM): The order is linked with Receivables and the invoice is created.

16) Partially Interfaced to Receivables (OM): This status is used in a PTO flow and indicates that the particular PTO item is required for revenue.

17) Closed (OM): Closed indicates that the line is closed.

18) Canceled (OM): Indicates that the line has been completely canceled. No further processing will occur for this line.

Monday, March 11, 2013

Query to find all the responsibilities attached to a User


SELECT fu.user_name, fr.responsibility_name, furg.start_date, furg.end_date
  FROM fnd_user_resp_groups_direct furg, fnd_user fu, fnd_responsibility_tl fr
 WHERE fu.user_name = user_name
   AND furg.user_id = fu.user_id
   AND furg.responsibility_id = fr.responsibility_id
   AND fr.LANGUAGE = USERENV ('LANG')

Query to find locked objects in Oracle


SELECT   c.owner, c.object_name, c.object_type, b.sid, b.serial#, b.status,
         b.osuser, b.machine, b.program, b.module, b.action
    FROM v$locked_object a, v$session b, dba_objects c
   WHERE b.sid = a.session_id AND a.object_id = c.object_id
ORDER BY module

Query to get Customer Related information for a Sales Order


SELECT ooh.order_number
     , hp_bill.party_name
     , hl_ship.address1 ||Decode(hl_ship.address2,NULL,'',chr(10))
      ||hl_ship.address2||Decode(hl_ship.address3,NULL,'',chr(10))
      ||hl_ship.address3||Decode(hl_ship.address4,NULL,'',chr(10))
      ||hl_ship.address4||Decode(hl_ship.city,NULL,'',chr(10))
      ||hl_ship.city    ||Decode(hl_ship.state,NULL,'',',')
      ||hl_ship.state   ||Decode(hl_ship.postal_code,'',',')
      ||hl_ship.postal_code ship_to_address
     , hl_bill.address1 ||Decode(hl_bill.address2,NULL,'',chr(10))
      ||hl_bill.address2||Decode(hl_bill.address3,NULL,'',chr(10))
      ||hl_bill.address3||Decode(hl_bill.address4,NULL,'',chr(10))
      ||hl_bill.address4||Decode(hl_bill.city,NULL,'',chr(10))
      ||hl_bill.city    ||Decode(hl_bill.state,NULL,'',',')
      ||hl_bill.state   ||Decode(hl_bill.postal_code,'',',')
      ||hl_bill.postal_code bill_to_address
     , ooh.transactional_curr_code currency_code
     , mp.organization_code
     , ooh.fob_point_code
     , ooh.freight_terms_code
     , ooh.cust_po_number,
,hcs_ship.site_use_id ship_to_location
, hcs_bill.site_use_id bill_to_location
FROM   oe_order_headers_all ooh
     , hz_cust_site_uses_all hcs_ship
     , hz_cust_acct_sites_all hca_ship
     , hz_party_sites hps_ship
     , hz_parties hp_ship
     , hz_locations hl_ship
     , hz_cust_site_uses_all hcs_bill
     , hz_cust_acct_sites_all hca_bill
     , hz_party_sites hps_bill
     , hz_parties hp_bill
     , hz_locations hl_bill
     , mtl_parameters mp
WHERE  1 = 1
AND    header_id =p_header_id
AND    ooh.ship_to_org_id = hcs_ship.site_use_id
AND    hcs_ship.cust_acct_site_id = hca_ship.cust_acct_site_id
AND    hca_ship.party_site_id = hps_ship.party_site_id
AND    hps_ship.party_id = hp_ship.party_id
AND    hps_ship.location_id = hl_ship.location_id
AND    ooh.invoice_to_org_id = hcs_bill.site_use_id
AND    hcs_bill.cust_acct_site_id = hca_bill.cust_acct_site_id
AND    hca_bill.party_site_id = hps_bill.party_site_id
AND    hps_bill.party_id = hp_bill.party_id
AND    hps_bill.location_id = hl_bill.location_id
AND    mp.organization_id(+) = ooh.ship_from_org_id