Professional Documents
Culture Documents
Extending 11i Advanced Pricing For Your Business Part 1: Using Attributes Mapping
Extending 11i Advanced Pricing For Your Business Part 1: Using Attributes Mapping
EXECUTIVE OVERVIEW
Oracle Advanced Pricing has a wide set of functionality provided in the out
of the box solution. However, there are frequently new innovations and ideas
generated in promoting/ pricing the product. Getting and keeping customers
and sales requires great capacity for flexibility in pricing. Because of lack of
flexibility, packaged pricing software frequently fails to meet the needs of eBusiness era companies. As a result, many companies find themselves making
significant and therefore expensive customizations to packaged software
pricing modules in order to meet their pricing business requirements, or go to
great expense to integrate new software with older legacy pricing applications.
This is precisely why Oracle Advanced Pricing provides a unique infrastructure
that allows you to tap into your pricing related business data and harness it
according to your pricing rules with a simple, non invasive extension that
allows you to define your own elements of pricing data to Advanced Pricing.
Advanced Pricing lets you avoid customizations by providing extension
capabilities like Attribute Mapping and get_custom_price routine in the
formula. This white paper explains Attributes Mapping . A separate white
paper explains Get_custom_price.
In this paper you will learn how you can use Attribute mapping to easily
extend Pricing to tap into data from a wide variety of non-standard sources to
drive your pricing. These data sources can be within Oracle Applications or
from outside Oracle Applications. Some typical, but by no means limited
examples of the uses of this capability include:
Defining a qualifier if today is Tuesday then given 10% off.
Define your own customer groupings that are in addition to the standard
groupings that are provided in Oracle Applications. You can use these groups
to control pricing such that if customer is in your special group A then 10%
is given, or if customer is in your special group B then a 7% discount is given.
Obtaining the cumulative value of sales over a long time period from a data
warehouse, and using this as a qualifier for a discount, rebate accrual, or other
pricing benefit.
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 2
Qualifiers :These are eligibility criteria. For example Customer class = VIP
or If today is Tuesday:
Product Hierarchy Element : A level in the product hierarchy at which pricing
characteristics are defined. Examples of product hierarchy elements are item
number, category, brand.
Customer Hierarchy Element: A level in the customer hierarchy at which
pricing characteristics are defined. Examples include customer groups not
definable using the standard Oracle Customer Master or Trading Community
Architecture definitions. Frequently, users define such groups in the flex fields
of the Oracle customer master.
Pricing Attributes : These are attributes which provide additional definition to
the Product. For example Cleanliness is a Pricing attribute of an item
Photocopier Service
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 3
1.
2.
Calling application then appends the User entered attributes and asked for
Qualifiers to this request.
3.
Calling application then calls Pricing Engine with these sourced attribute
values.
4.
5.
Pricing engine processes the request and returns the results to the calling
application.
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 4
Defining Context
2.
3.
2.
Page 5
Name: Give a name which is unique. Please make sure that the Name
is pre-fixed with your own custom prefix(other than QP) to prevent
any accidental overwrite by future pricing seed data uploads.
Column : Choose a segment from the list. This value would be stored
in the QP setup tables. This value also would be used in the Attribute
Mapping. For example qualifier_attribute30/pricing_attribute30.
Note : Segments numbering less than 30 are reserved for future use by
pricing. By default only 30 segments are enabled.
More segments can be enabled using the screen -- flexfields->descriptive-->register
Value set provides the list of values for the pricing element. For example if my
qualifier is customer region then the value set needs to provide valid list of
values for the customer region. Attaching value set is a mandatory step for the
pricing elements to be usable in pricing. As a general principle it is
recommended that the value set should be from setup tables and not from
transaction tables. (for example the valueset for Brand should be from the
table where list of brands are stored and not from
mtl_system_items_b.segment6 ). Please also note that as of now advanced
pricing does not support dependent valuesets.
Steps:
1.
Choose an existing valueset or create a new one by clicking on the Value Set
button. Please note that whatever defined in the Value Column is displayed in
the value column of the qualifiers window. Meaning column is used in the
LOV in the Qualifiers window while selecting a qualifier.
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 6
2.
3.
Choose the format type. If the value is number choose a number, for date
choose standard date or for character choose char
4.
5.
Warning: Please note that the qualifier and Pricing attributes datatype is derived
from the valueset . Advanced Pricing does not support changing the datatype of
a qualifier/pricing attributes once that qualifier/atttribute is used in setup. Not
following this will result into pricing engine failure and potential data issues.
Also please note that OM Family patchset D or QP patch 1508982 has
introduced a faster algorithm which uses this datatype for evaluating the
Note: Consideration for Breaks on attributes other than Qty. If the volume
breaks are defined based on attributes other than qty then it is assumed that the
pricing attribute is and the break are in the matching UOM.
For example if a volume break is defined on an attribute called Age in Years
then it is assumed that the Age in Years is sourced as Age in years. Pricing
Engine has no knowledge of the UOM of the pricing attribute hence no
conversion can be performed
Commit the record and compile the flexfield and make sure that the
concurrent program completes successfully
ATTRIBUTES MAPPING
After finishing the flex field setup you can start the setup activities of creating
modifiers and attaching qualifiers or product hierarchy elements. However
Pricing engine will not know where to find/ derive the values of these
elements at the run time. Hence Attributes Mapping is a mandatory step
before any pricing element is used by the Pricing engine. Pricing engine also
provides a flexibility that a transaction area can define the attributes mapping
specific for its use. For example Customer Region may be derived from a
OE_ORDER_PUB.G_HDR.sold_to_org_id for Order Management.
However this same element may have to be derived from
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 7
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 8
1.
To enter a sourcing rule for a qualifier, query for entities Header Qualifier
Attrs and Line Qualifier Attrs
2.
To enter a sourcing rule for a pricing attribute , query for entities Header
Pricing Attrs and Line Pricing Attrs
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 9
The source system that uses this condition: For example, ONT
Enter 1 in Group#
Validation operation is =
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 10
1.
Validation Operation is =
Enter 1 in Sequence
Profile Option
PL/SQL API
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 11
Constant
System Variable
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 12
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 13
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 14
6.
Note: Please note that Pricing Build Sourcing Rules concurrent program is different from Order
Managements Generate Defaulting Rules program.
6.
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 15
NOTE
1.
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 16
changed. Also
2.
CONCLUSION
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 17
Introduction
This is an example of using Attributes Mapping for custom sourcing. The
example also uses the pricing formula.
Background
Commonly in advanced pricing, there is a need to retrieve data from
sources that were not set up as part of the standard installation.
This document details the setup required to retrieve data using custom
code into pricing for use with pricing formulae. Similar setup can be used
for qualifiers however this is not documented here.
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 18
Flexfield Setup
It is assumed for this section that the reader knows how to configure
flexfields within Oracle Applications 11i.
For custom sourcing, the flexfield against the table
QP_ATTRIBUTE_DEFNS should be modified. This flexfield is actually
defined twice in the system. Once as 'Qualifier Contexts' and once as
'Pricing Contexts'.
For the examples in this document, we are only examining 'Pricing
Contexts'
Navigation Path & Responsibility:
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 19
Formula Header:
In the tables on the
following pages, the
formula header
tables relate to the
header
region of this form
Formula Lines:
In the tables on the
following pages, the
formula lines tables
relate to the lines
region of this form.
(Any fields not included in the following tables should be left as their
default value or blank)
Please note, the pricing formulae are dependent on flexfield setups being
completed for the pricing flexfields.
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 20
Cost+25% Formula
Formula Header:
Name
Description
Formula
Cost Plus 25
Percent
1 * NVL(2, 3)
Formula Lines:
Formula Type Pricing
Attribute
Context
Pricing
Attribute
Numeric
Constant
Pricing Attribute
Pricing
Attribute
Component
Step
1.25
ITEM_COST
List Price
2
3
Server Installation
Write Custom Package
You need to write supporting code to pull data from whatever data
source. As this point, you are only concerned with what data you wish to
retrieve, not where it will go.
Each piece of custom sourcing code you write should be grouped in a
single pl/sql package for ease of maintenance. In our example, we will use
a package called my_custom_sourcing.
Custom sourcing is managed by writing small pl/sql stored functions. In
this example, it must return a single value.
This example will retrieve the cost of an item from cst_item_costs based
on inventory_item_id. It is imperative that the performance of this
function is tuned as this function will be called thousands of times a day.
To improve performance, it is often wise to cache the most recent input
and output values for the function.
Copy the code given in appendix b and modify as required.
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 21
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 22
You should see the following screen: (Defaulting Setup - Entity Attributes
form.)
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 23
Select your Required pricing Attribute and click on 'Defaulting Rules' Note the required attributes are listed with their individual setup on the
following pages.
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 24
Column Name
Precedence
Defaulting
Condition
Value
2
ONT Pricing Attributes
Context
After you have created this row, while it is still selected enter the following
details on a new row in the Default Sourcing Rules Section:
Column Name
Value
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 25
Sequence
Source Type
1
PL/SQL API
Column Name
Package Name
Function Name
Value
MY_CUSTOM_SOURCIN
G
get_item_cost(oe_order_pub
.g_line.inventory_item_id)
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 26
ATT #
100
PRICING_ATTRIBUTE20
DISPLAY
SIZE
DISPLAY
ITEM_COST
22
REQUIRE
VALUE SET
FND_NUMBER15
Oracle Corporation 2001. This Document is provided for informational purposes only and the
information herein is subject to change without notice.
Page 27
APUN
Item_Info_Rec_Type;
Oracle Corporation 2001. This Document is provided for informational purposes only and the information
herein is subject to change without notice
Page 1
NUMBER) IS
= cp_item_id
= 1
=
Oracle Corporation 2001. This Document is provided for informational purposes only and the information
herein is subject to change without notice
Page 2
ELSE
-- if the requested agreement is NOT cached
then retrieve
-- the value from the flexfield.
OPEN cs_item_cost(p_item_id);
FETCH cs_item_cost INTO v_cost;
CLOSE cs_item_cost;
-- if we didn't get anything, default to
NULL
IF v_cost IS NULL THEN
v_cost := NULL;
END IF;
-- store the data in global record.
-- so that we don't have to keep reading
from the tables.
G_Item_Info.inventory_item_id := p_item_id;
G_Item_Info.item_cost := v_cost;
END IF;
RETURN G_Item_Info.item_cost;
EXCEPTION
WHEN OTHERS THEN
-- you may also wish to clear the cached
item id if you hit an exception.
-- In this example I don't.
G_Item_Info.item_cost := NULL;
RETURN G_Item_Info.item_cost;
END Get_Item_Cost;
END MY_CUSTOM_SOURCING;
/
Oracle Corporation 2001. This Document is provided for informational purposes only and the information
herein is subject to change without notice
Page 3
IExtending 11i Advanced Pricing for Your Business Part 1: Using Attributes Mapping
March 2001
Author: Nitin Hase
Contributing Authors: Jayrama Holla, Tony Maxey, Jeff Lee, Simon Cromarty
Oracle Corporation
World Headquarters
500 Oracle Parkway
Redwood Shores, CA 94065
U.S.A.
Worldwide Inquiries:
Phone: +1.650.506.7000
Fax: +1.650.506.7200
Web: www.oracle.com
This document is provided for informational purposes
only and the information herein is subject to change
without notice. Please report any errors herein to
Oracle Corporation. Oracle Corporation does not
provide any warranties covering and specifically
disclaims any liability in connection with this document.
Oracle is a registered trademark, and Oracle Order Management is (are) a
trademark(s) or registered trademark(s) of Oracle corporation.
All other names may be trademarks of their respective owners.
Copyright Oracle Corporation 2000
All Rights Reserved