Calling messages: Following standard procedure can be called to show predefined oracle applications message through forms or concurrent programs.

FND_MESSAGE.CLEAR – Clears the message stack of all the messages.

FND_MESSAGE.DEBUG – Immediately displays the string passed to it as input parameter.

FND_MESSAGE.ERASE – Clears the oracle Forms status line.

FND_MESSAGE.ERROR – Displays an error message in an Oracle Forms modal window or a concurrent program log file. (Example: “Invalid value entered.”). It takes its message from the stack, displays the message, and then clears all the messages from the message stack.

FND_MESSAGE.GET – Retrieves a translated and token–substituted message from the message stack and then clears that message from the message stack. This could be used for getting a translated message for a forms built–in or other function. Assumes you have already called FND_MESSAGE.SET_NAME and, if necessary,
FND_MESSAGE.SET_TOKEN. It returns up to 2000 bytes of message.

FND_MESSAGE.HINT – Displays a message in the Oracle Forms status line. It takes its message from the stack, displays the message, and then clears that message from the message stack. The user may still need to acknowledge the message if another message immediately comes onto the message line.

FND_MESSAGE.QUESTION – Displays a message and up to three buttons in an Oracle Forms modal window. (Example: “Please choose one of the following actions: ”) It takes its message from the stack, and clears that message. After the user selects a button, It returns the number of the button selected.
For each button, you must define or use an existing message in Message Dictionary (under the Oracle Application Object Library application) that contains the text of the button. This routine looks for your button name message in the Oracle Application Object Library messages, so when you define your message, you must associate it with Oracle Application Object Library (the “FND” application) instead of your application.

FND_MESSAGE.RETRIEVE – Retrieves a message from the database server, translates and substitutes tokens, and sets the message on the message stack.

FND_MESSAGE.SET_NAME – Retrieves your message from Message Dictionary and sets it on the message stack. You call it once for each message you use in your client–side PL/SQL procedure. You must call this procedure before you call FND_MESSAGE.SET_TOKEN.

FND_MESSAGE.SET_STRING – Takes an input string and sets it directly on the message stack. The string does not need to be defined in the Messages window. These strings may be hard coded into the form and are not translated like messages defined in Message Dictionary.

FND_MESSAGE.SET_TOKEN – Substitutes a message token with a value you specify. You call FND_MESSAGE.SET_TOKEN once for each token/value pair in a message. The optional translate parameter can be set to TRUE to indicate that the value should be translated before substitution. (The value should be translated if it is, itself, a Message Dictionary message name.)

FND_MESSAGE.SHOW – Displays an informational message in an Oracle Forms modal window or a concurrent program log file. (Example: “To complete this function, please enter the following… ”). It takes its message from the stack, displays the message, and then clears only that message from the message stack.

FND_MESSAGE.WARN – Displays a warning message in an Oracle Forms modal window and allows the user to either accept or cancel the current operation. (Example: “Do you wish to proceed with the current operation?”) FND_MESSAGE.WARN returns TRUE if the user accepts the message (that is, clicks OK), or FALSE if the user cancels. It takes its message from the stack, displays the message, and clears that message from the message stack.
Most frequently used procedures are FND_MESSAGE.SET_NAME and FND_MESSAGE.SET_TOKEN

Example
/*Here FND_MESSAGE.SET_NAME is used to retrieve the message and put it on the message stack. Message name is ‘WANT TO CONTINUE’.*/

FND_MESSAGE.SET_NAME (’FND’, ‘WANT TO CONTINUE);

/*Next FND_MESSAGE.SET_TOKEN is used to replace the token ‘PROCEDURE’ with text ‘Compiling this flexfield’.

FND_MESSAGE.SET_TOKEN (’PROCEDURE’, ’Compiling this flexfield’);

IF FND_MESSAGE.WARN THEN
/* User want to continue */

ELSE
/* User want to cancel*/

END;

FND_GLOBAL.APPS_INITIALIZE is used for initializing the session before calling any public or private API’s in Oracle Ebusiness suite. Its not required for all the API’s but its recommended that you set this profile before making any calls to either private or public API. 


Listed below is a sample call to FND_GLOBAL.APPS_INITIALIZE function


fnd_global.APPS_INITIALIZE(user_id=>l_user_id, 
                           resp_id=>l_resp_id, 
                           resp_appl_id=>l_resp_appl_id);


l_user_id is the fnd user ID which will be utilized during the call. 
l_resp_id is the responsibility ID 
l_resp_appl_id is the responsibility application ID. 
You can use either sysadmin or use some user who has all the above listed responsibilities.


For SYSADMIN, utilize the following query to get the respective values


select fnd.user_id , 
       fresp.responsibility_id, 
       fresp.application_id 
from   fnd_user fnd 
,      fnd_responsibility_tl fresp 
where  fnd.user_name = ‘SYSADMIN’ 
and    fresp.responsibility_name = ‘Order Management Super User’;


Another option is Help > Diagnostics > Examine and get the values from $profile session values.

As we all know there are two mandatory parameters that need to be pased for all the procedures called
1.ERRBUFF
2.RETCODE..

Based on the business process if there is any undefined exeception occured while running concurrent program, we can end the concurrent program with Error/Warning.

Define ERRBUFF as the first parameter and Retcode as the second one. Mention the OUT variable type.

CREATE PROCEDURE PROCEDURE_NAME (errbuf  OUT VARCHAR2,
                                 retcode OUT VARCHAR2)

The retcode has three values returned by the concurrent manager
0–Success
1–Success & warning
2–Error

we can set the concurrent program to any of the three status by using these values in the retcode parameter

Example:
========

BEGIN
…..
EXCEPTION
     WHEN OTHERS THEN
        FND_FILE.PUT_LINE(FND_FILE.LOG,’Unhandled exception occurred in package. ErrMsg: ‘||SQLERRM);
        retcode=’2′;
END;

Even you can use fnd_concurrent.set_completion_Status to send the concurrent program to more status than success,error and warning.

Types of Invoices in AP:

The different types of invoices available in Payables are:

1. Standard Invoices: Standard invoices are the invoices issued by a supplier to the buyer, representing the amount due for the products or services the supplier has provided to the buyer.

Standard invoices can be either matched to a purchase order or not matched.

A standard invoice must be positive amount.

2. Mixed Invoices: Mixed invoices are the invoices which can have either positive or negative amounts and can be matched to both purchase orders and invoices.

For example, if there is a mixed invoice for $-1000, you can either match it to an invoice with $-1000 or to a purchase order with an amount $1000.

3. Credit Memo: Credit memo is an invoice raised by the supplier to the buyer with negative amount. It reduces the supplier balance and reduces the liability.

For example the customer has returned some of the goods that he purchased, the supplier sends a credit memo to the buyer to adjust the balance.

4. Debit Memo: Debit memo is an invoice raised by the customer to supplier with negative amount.

The functionality of Debit Memo is same as Credit Memo. Both are to reduce the liability.

The purpose of Debit Memos is to record a credit for a supplier who does not send you a credit memo.

Unlike in AR, both Credit memo and Debit memo are with negative signs in Payables.

5. Prepayment: Prepayments are the invoices raised to record advance payments to a supplier or employee.

6. Expense Reports: Expense reports are the invoices that represent amount due to an employee for all his business related expenses.

7. Retainage Release Invoices: Retainage release is the act of releasing, or paying, that portion of a payment that was withheld until a substantial portion or all of the service procurement work is completed. The amounts retained during the life of the contract must be released and paid to the supplier or sub-contractor once all or a substantial portion of the work is completed.

Oracle Payables uses the Retainage Release Request to create a type of invoice called Retainage Release. A retainage release invoice has lines, which are copied from the original standard progress invoices, which show an amount left to be released.

Retainage release invoices can only be entered manually in the Invoice Workbench window.


8. Withholding Tax:  After you apply withholding tax to an invoice, you can optionally create invoices to remit withheld tax to the tax authority.
                          
Payables can automatically create withholding tax invoices, or you can perform this
task manually. If you choose to automatically create withholding tax invoices, you must choose whether to do this during Invoice Validation or during payment processing.


9. PO Price Adjustment Invoices:  PO Price Adjustment Invoices are used for recording the difference in price between the original invoice and the new purchase order price.

For example, If a supplier sends an invoice for a change in unit price for an invoice you have matched to a purchase order, PO Price Adjustment Invoices can be used to adjust the invoiced unit price of previously matched purchase order shipments or distributions without adjusting the quantity billed.

PO price adjustment invoices can be matched to both purchase orders and invoices.

10. Quick invoices: Used for quick, high-volume invoice entry for invoices that do not require extensive validation and defaults. After entry, you import these into the Payables system. Validation and defaulting occur during import

ORDER MANAGEMENT Interview Questions
Q: What are the Process Constraints?
A: Processing Constraints allow Order Management users the ability to control changes to sales orders, at all stages of its order or line workflows to avoid data inconsistencies and audit problems.
Q: What is a Pick Slip Report?
A: Pick slip is a shipping document that the pickers use to locate items in the warehouse/ inventory to ship for an order.
Q: At what stage an order cannot be cancelled?
A: If the order is Pick Confirmed, it cannot be cancelled.
Q: When the order import program is run it validates and the errors occurred can be seen in?
A: Order Management Responsibility >Orders, Returns : Import Orders> Corrections
Q: What is the difference between purchase order (PO) and sales order?
A: Purchase Order: The document which is created and sent to supplier when we need to purchase something. (Buying)

Sales Order: The document which is created when customer places an order to buy something. (Selling)
Q: What are primary and secondary price lists?
A: Price list contains information on items and its prices. The pricing engine uses secondary price lists when it cannot determine the price for an item using the price list assigned to an order.
Q: Name some tables in shipping/order/move order/inventory?
A: WSH_DELIVERY_DETAILS,WSH_NEW_DELIVERIES, OE_ORDER_HEADERS_ALL, OE_ORDER_LINES_ALL, MTL_SYTEM_ITEMS_B, MTL_MATERIAL_TRANSACTIONS
Q: How is move order generated?
A: When the order is pick released.
Q: What is ONT stands for?
A: ORDER MANAGEMENT
Q: What does Back ordered mean in OM?
A: An unfulfilled customer order due to non-existence of the ordered items in the Inventory.
Q: What are picking rules?
A: A user-defined set of criteria to define the priorities Order Management uses when picking items out of finished goods inventory to ship to a customer. Picking rules are defined in Oracle Inventory.

Q: What is drop ship in OM?
A: A method of fulfilling sales orders by selling products without handling, stocking,or delivering them. The selling company buys a product from a supplier and has the supplier ship the product directly to customers.
Q: What are Defaulting Rules?
A: While creating the order,you can define defaulting rules so that the default values of the fields pop up automatically instead of typing all information.
Q: What are validation templates?
A: A validation template names a condition and defines the semantics of how to validate that condition. Validation templates can be used in the processing constraints framework to specify the constraining conditions for a given constraint.
Q: What are different Order Types?
A: Order Only, Mixed, RMA

Q: Explain the Order Cycle?
A: Book the order
Pick Release
Pick Confirm
Ship Confirm
Close the order
Q: What is packing slip?
A: An external shipping document that is sent along with a shipment itemizing in detail the contents of that shipment.
Q: When an order cannot be deleted?
A: Order cannot be delted if the Order is Pick Confirmed.
Q: What is pick slip?
A: Pick slip is a shipping document that the pickers use to locate items in the warehouse/ inventory to ship for an order.

Q: What is Drop shipment?
A: Drop Shipment is a process where the customer places a purchase order on a company and this company instructs its supplier to directly ship the items to the customer.