Sunteți pe pagina 1din 14

Oracle Pricing:

It provides an advanced, highly flexible pricing engine that executes pricing calculations for
Oracle Order Management. Some of the features which Pricing allows you are:

 Apply a surcharge
 Discounts by percentage or amount
 Calculate the price of order lines using list prices specified in price lists and pricing
formulas.
 Apply price modifiers/qualifiers that you define to a line.
 Calculate freight charges and show it as a separate component in Order Management

Concepts in pricing

Price Lists
Price lists are essential to ordering products because each item entered on an order must have a
price. Each price list contains basic list information like price list name, effective dates, currency,
pricing controls,rounding factor,shipping defaults such as freight terms and freight carrier,and
one or more pricing lines, pricing attributes.

Pricing Formulas
Formulas are mathematical expressions that the pricing engine uses to determine the list prices of
items and the discounts that apply to those items.

Price List Qualifiers/Modifiers

Price List Qualifiers/Modifiers Modifiers enable you to setup price adjustments (for example,
discounts and surcharges) and freight and special charges (modifier lists) that the pricing engine
applies immediately to pricing requests.Using modifiers you can:

 Setup a modifier list with multiple modifier lines


 Create eligibility rules for modifiers by assigning list and line level qualifiers
 Qualifiers help the pricing engine to determine who is eligible for the modifier.

Pricing Attributes

Pricing attributes are characteristics of products and services that specify when the characteristics
help to determine the price of a product or service. Distance, age of a related product, customer
class, product family group, and level of service are examples of pricing attributes. You can
specify one or a combination of pricing attributes and assign them to a product. At order entry
time, the pricing engine evaluates the attributes you have specified during formula setup to
calculate the price.
Steps for pricing an order

 Create a price list (one time)


 This includes creation of price list headers and lines(which associates items to a
particular price)
 Create pricing formulas (optional)
 Create price list modifiers/qualifiers (optional)
 Create an order.
 Attach the price list to that order

Advance Pricing APIs and Key Tables

Oracle Advance Pricing provides a set of APIs which can be used to perform some of the key
pricing functions. The below are some of the important APIs.
QP_PREQ_GRP.Price_Request: This is the Price Request API to calculate the base price.
This is a public API that allows you to get a base price and to apply price adjustments, other
benefits, and charges to a transaction. This API can be called any module to calculate the base
price which are integrated with the Advance Pricing Module.
QP_CUSTOM.Get_Custom_Price : This API works like a hook in Oracle Advance Pricing.
This is function provided by the oracle We need to override the body of this package function in
order to add custom functionality. We can add custom code to this customizable function. When
the pricing engine executes to calculate the base price , it executes the logic inside this function if
it found a formula line in the price list.
QP_CUSTOM_SOURCE.Get_Custom_Attribute_Values : 
Attributes can also be passed to the pricing engine directly, without the need for an attribute
mapping rule. In such cases, the Attribute Manager API calls the QP_CUSTOM_SOURCE API,
where the user has manually defined the attributes being passed and coded the sourcing of their
values.
The user code is written in the package procedure
QP_CUSTOM_SOURCE.Get_Custom_Attribute_Values.
The Attribute Manager API program (Build_Contexts), calls this procedure to pick up custom-
sourced attributes if the profile option QP: Custom Sourced is set to Yes. The input parameters to
QP_CUSTOM_SOURCE are Request Type code and Pricing Type. Typical values of Request
Type Codes that can be passed are ONT, ASO, OKC, IC, FTE or MSD. By using the
Request_Type_Code, the user can control how the attributes are sourced based on the PTE of the
calling application.The Pricing Type can be H (Header) or L (Line) which defines the level of
the attribute mapping rule. These attributes and their values are passed to the pricing engine in
the same manner as the attributes sourced through attribute mapping rules.
Key Tables
 QP_PRICING_ATTRIBUTES
 QP_LIST_LINES

 QP_LIST_HEADERS_B
 QP_QUALIFIERS
 QP_PRICING_ATTRIBUTES
 QP_LIST_LINES
 QP_LIST_HEADERS_B
 QP_SEGMENTS_B
 QP_PRC_CONTEXTS_B
 QP_PTE_SOURCE_SYSTEMS
 QP_ATTRIBUTE_SOURCING
 QP_PTE_REQUEST_TYPES_B
 QP_PTE_SEGMENTS
 QP_PRICING_PHASES
 QP_EVENT_PHASES
 OE_PRICE_ADJUSTMENTS
 OE_PRICE_ADJ_ATTRIBS
 OE_PRICE_ADJ_ASSOCS

The tables are as follows:


• OE_PRICE_ADJUSTMENTS
– Holds the price adjustments
• OE_PRICE_ADJ_ATTRIBS
– Holds the qualification conditions applied to give the adjustments
• OE_PRICE_ADJ_ASSOCS
– Holds relationships between multiple adjustment records for price breaks, promotional goods
and other item benefits
– QP_PREQ_LINES_TMP
– Has Line and Order details
– QP_PREQ_LINES_ATTRS_TMP
– Has product and pricing attribute details of a particular line
– QP_PREQ_RLTD_LINES_TMP
– Has the relation b/w lines in QP_PREQ_LINES_TMP
– QP_PREQ_LDETS_TMP
– Has the details about the modifier line and pricelist line got selected for a particular line
– QP_PREQ_QUAL_TMP
– Has qualifier attribute details of a particular line
Error Handling:
– If the pricing engine call is a success , if the value of x_return_status is
FND_API.G_RET_STS_SUCCESS.
• Error Statuses
– G_STATUS_INVALID_PRICE_LIST
– G_STS_LHS_NOT_FOUND
– G_STATUS_FORMULA_ERROR
– G_STATUS_OTHER_ERRORS
– G_STATUS_CALC_ERROR
– G_STATUS_UOM_FAILURE
– G_STATUS_INVALID_UOM
– G_STATUS_ DUP_PRICE_LIST
– G_STATUS_INVALID_UOM_CONV
– G_STATUS_INVALID_INCOMP
– G_STATUS_BEST_PRICE_EVAL_ERROR
– FND_API.G_RET_STS_UNEXP_ERROR
– FND_API.G_RET_STS_ERROR
• Price List fetched for an request line.
– The price_list_id is populated on the price_list_id column in the qp_preq_lines_tmp.
– The List price (undiscounted base price ) is returned in unit_price
– The discounted price (After applying all the discounts/surcharges) is in adjusted_unit_price
– Priced_quantity holds the line_quantity (Order Line quantity) expressed in pricing_uom_code
• Modifiers fetched for an order line.
– qp_preq_ldets_tmp : Hold the information about the applied modifiers
– qp_preq_rtd_lines_tmp : Holds the relationship between the modifiers applied.

How to list down Attribute Mapping Rules in Oracle


Advanced Pricing:
SELECT QPSEG.SEGMENT_MAPPING_COLUMN, QPSOUR.USER_SOURCING_TYPE,

QPSOUR.USER_VALUE_STRING, QPCON.PRC_CONTEXT_CODE,

QPSOUR.ATTRIBUTE_SOURCING_LEVEL, QPSOUR.REQUEST_TYPE_CODE,

QPREQ.PTE_CODE, QPCON.PRC_CONTEXT_TYPE, QPSEG.SEGMENT_CODE,

QPCON.SEEDED_FLAG CONTEXT_SEEDED_FLAG,

QPSEG.SEEDED_FLAG ATTRIBUTE_SEEDED_FLAG

FROM QP_SEGMENTS_B QPSEG,

QP_ATTRIBUTE_SOURCING QPSOUR,
QP_PRC_CONTEXTS_B QPCON,

QP_PTE_REQUEST_TYPES_B QPREQ,

QP_PTE_SEGMENTS QPPSEG

WHERE QPSOUR.SEGMENT_ID = QPSEG.SEGMENT_ID

AND QPPSEG.USER_SOURCING_METHOD = ‘ATTRIBUTE MAPPING’

AND QPSOUR.REQUEST_TYPE_CODE = ‘ONT’

AND QPSEG.PRC_CONTEXT_ID = QPCON.PRC_CONTEXT_ID

AND QPREQ.REQUEST_TYPE_CODE = QPSOUR.REQUEST_TYPE_CODE

AND QPPSEG.PTE_CODE = QPREQ.PTE_CODE

AND QPPSEG.SEGMENT_ID = QPSOUR.SEGMENT_ID

AND QPPSEG.SOURCING_ENABLED = ‘Y’

AND QPCON.PRC_CONTEXT_TYPE IN

(‘PRICING_ATTRIBUTE’, ‘PRODUCT’, ‘QUALIFIER’);

How to Define Event Phases in Oracle Advanced Pricing


Events are points in pricing process flow when the calling application sends a pricing request to
the pricing engine (similar to a workflow event). The information that the pricing engine returns,
for example, base prices, price adjustments, promotions, or freight charges, depends on the
pricing phases of the event.

A pricing phase controls what modifiers are considered by the pricing search engine and in
what sequence they should be applied to the request. The attributes of a pricing phase allow us
to control which modifiers can be placed in a phase. (Metalink)

Example

We need to Apply Surcharge at two events when order booked and when order line entered so
we need to define event phase as shown in following picture.
To Define Event Phase

Navigate to

Setup  Event Phases

By using Oracle Pricing manager Responsibility

When we assign a modifier to a pricing phase the Modifier Setup form matches the attributes of
the modifier to the attributes of the available pricing phases to validate which pricing phase or
phases a modifier can be placed in. A Modifier can only be assigned to one Phase

Now Map This Event Phase in Modifier interface as shown below

Tables Used in Pricing


Following Tables used to store all price List Data and used Frequently in reporting and oracle
Internal operations

 OE_PRICE_ADJUSTMENTS
This table is used to store price adjustments that have been applied to an order or a line. The
column automatic flag indicates if the adjustment was applied automatically or manually.
Manual discounts are created with applied_Flag = Y.
SELECT price_adjustment_id, creation_date, header_id “Order Header”,
automatic_flag “discount applied automatically”,
line_id “ORDER LINE_ID”,
orig_sys_discount_ref “Original discount reference”,
list_header_id “Header Id of the Modifier”,
list_line_id “Line id of the Modifier”,
list_line_type_code “Line Type of the Modifier”,
accrual_flag “adjustment is accrued”, benefit_qty “Quantity accrued”,
benefit_uom_code
FROM ont.oe_price_adjustments

 OE_PRICE_ADJ_ATTRIBS

This table stores information on qualifiers and pricing attributes, which to that corresponding
price adjustment line qualified for “price_adjustment_id” is link between this table and
ont.oe_price_adjustments

SELECT price_adjustment_id,

pricing_attr_value_from “from Value pricing Attribute”,

pricing_attr_value_to “To Value pricing Attribute”,

comparison_operator “Operators”,

flex_title “pricing_context Flex_name”, price_adj_attrib_id,

lock_control

FROM ont.oe_price_adj_attribs;

 OE_PRICE_ADJ_ASSOCS

This table stores the association between Order lines and price adjustments and also between
price adjustments. One adjustment may be a result of benefit on one or more order lines.
“price_adjustment_id” is link between this table and ont.oe_price_adjustments

SELECT line_id “Order Line Id”, price_adjustment_id,

rltd_price_adj_id “price_adjustment_id”

FROM ont.oe_price_adj_assocs;
SOME OF THE MAIN PRICING API’s AVAILABLE
Business Object for Pricing Formulas Application Program Interface

· QP_Price_formula_PUB.Get_Price_Formula
The Formula Calculation package retrieves the price formula header and lines for a given
formula.
· QP_Price_formula_PUB.Process_Price_Formula
Performs the insert, update, and delete of price formula header and price formula lines.
· QP_Price_formula_PUB.Lock_Price_FormulaLocks price formula header and price formula
lines records prior to updates

Get Custom Price Used in Formulas Setup) Application Program Interface

· QP_CUSTOM.Get_Custom_Price
You may add custom code to this customizable function. The pricing engine while evaluating a
formula that contains a formula line (step) of type “function” calls this API.

Request Application Program Interface

· QP_PREQ_GRP.Price_Request
The Price Request Application Program Interface (API) is a public API that allows you to get a
base price and to apply price adjustments, other benefits, and charges to a transaction.

HOW ORACLE PRICING WORKS


Pricing Engine takes the pricing request from the calling application, selects the applicable price
lists and modifier lists and determines the base list price. It then calculates the final selling price
by applying the benefits and surcharges from the modifier lists to the base list price
How to Setup Manual Modifier for Special Charges

Oracle Advance Pricing Facilitate us to define manual adjustments for discounts, surcharges and
freight charges. In order to override the selling price directly on the order or apply any surcharge,
we must define a manual surcharge.

Following are the steps with screen shot that how to define manual surcharge modifier

Define Modifiers
Navigate to
Modifiers –> Modifier Setup
By using Oracle Pricing Manager Responsibility
Fill the information as per following
In Header Block on Main (T)
Type :- Freight and Special charge List
Name :- XX Manual Modifier (its on your own discretion)
Number :- ABC123 (its on your own discretion)
Active :- Check this Box
Automatic :- Leave Unchecked (To inform system this is a manual modifier)
Description :- Manual Modifier for Demonstration

In Detail Block on Modifiers Summary (T)


Modifier Number :- System Will Automatically generate this number
Level :- Order
Modifier Type :- Freight/Special Charge
Pricing Phase :- Header Level Adjustments
In Detail Block on Discounts/Charges (T)
Charge Name: – Administration Fees
Application Method :- Lumpsum
Value :- 5000

Save all the information

Build Attribute Mapping


Navigate to
Reports
By using Oracle Pricing Manager Responsibility and submit the request named “Build
Attribute Mapping Rules” with default parameters
 

Apply Surcharge on Order


Navigate to
Orders. Returns  Sale Orders
By using Order Management Super User Responsibility
Enter and Save an Order

After Clicking on Action (B) a list of value will popped up select “Charges” as shown in
picture below
A new interface will appear select charge “Administration Fees” defined earlier all related
information automatically retrieved upon selection of charge name and
Click on Apply Button and look at charges field on main Page of Order Entry Form our manual
surcharge is applied

S-ar putea să vă placă și