100% found this document useful (2 votes)
1K views

Extensibility of The Sales and Distribution Price List: SAP Enhancement Package 7 For SAP ERP 6.0

Uploaded by

Dmitry Popov
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (2 votes)
1K views

Extensibility of The Sales and Distribution Price List: SAP Enhancement Package 7 For SAP ERP 6.0

Uploaded by

Dmitry Popov
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 20

Extensibility Documentation CUSTOMER

SD Price List Report Document Version: 1.1 – 2016-02-11

Extensibility of the Sales and Distribution Price List


Report
SAP Enhancement Package 7 for SAP ERP 6.0
Typographic Conventions

Type Style Description

Example Words or characters quoted from the screen. These include field names, screen titles,
pushbuttons labels, menu names, menu paths, and menu options.
Textual cross-references to other documents.

Example Emphasized words or expressions.

EXAMPLE Technical names of system objects. These include report names, program names,
transaction codes, table names, and key concepts of a programming language when they
are surrounded by body text, for example, SELECT and INCLUDE.

Example Output on the screen. This includes file and directory names and their paths, messages,
names of variables and parameters, source text, and names of installation, upgrade and
database tools.

Example Exact user entry. These are words or characters that you enter in the system exactly as
they appear in the documentation.

<Example> Variable user entry. Angle brackets indicate that you replace these words and characters
with appropriate entries to make entries in the system.

EXAMPLE Keys on the keyboard, for example, F 2 or E N T E R .

CUSTOMER
© 2012 SAP AG. All rights reserved. 2
Document History

Version Date Change

1.0 10FEB2014 First version

1.1 11FEB2016 Version 1.1

CUSTOMER
© 2012 SAP AG. All rights reserved. 3
Table of Contents

1 Extensibility New SD Price List .................................................................................................. 5


1.1 API_PIQ_SDPRICELIST ......................................................................................................................... 5
1.1.1 Parameters ............................................................................................................................ 5
1.2 BAPI_PIQ_SDPRICELIST ...................................................................................................................... 6

2 Enhancements of the Price list report ....................................................................................... 8


2.1 Extensibility of Output and Selection Criteria ..................................................................................... 8
2.1.1 Customizing Table PIQC_TABMETADT_S / PIQC_TABMETADT_C ................................ 8
2.1.2 Customizing Table PIQC_FIELD_LST_S / PIQC_FIELD_LST_C ....................................... 9
2.1.3 Customizing Table PIQC_DB_ALIAS_S/ PIQC_DB_ALIAS_C ........................................... 9
2.2 Extensibility of Pricing Attributes ....................................................................................................... 10
2.3 Enhancement Points in Transaction V_NLN / Report SDPIQPRICELIST ....................................... 11
2.4 BAdIs......................................................................................................................................................12
2.4.1 BADI_PIQ_SDPRICELIST.....................................................................................................12
2.4.2 BADI_PIQ_SDPRICELIST_OUTPUT....................................................................................13

3 Enhancements in the Price Inquiry API .................................................................................... 14


3.1 Mapping of Pricing Attributes..............................................................................................................14
3.1.1 Identifying Fields Used in Own Pricing Enhancements ....................................................15
3.2 BAdI BADI_PIQ_PREPARE ...................................................................................................................15
3.2.1 Method ADAPT_HEAD_ITEM_DATA ..................................................................................15
3.2.2 Method ADAPT_KOMK_KOMP_DATA ...............................................................................15

4 Example ................................................................................................................................ 16
4.1 Scenario.................................................................................................................................................16
4.2 Assumptions .........................................................................................................................................16
4.3 Enhancing the Price List Report .......................................................................................................... 17
4.3.1 Adding a Field as a Selection Criteria ................................................................................. 17
4.3.2 Adding the Field in the Output Table ..................................................................................18
4.4 Enhancing Price Inquiry API ................................................................................................................19

CUSTOMER
© 2012 SAP AG. All rights reserved. 4
1 Extensibility New SD Price List

The new Creation of Price Lists (transaction V_NLN) (SDPIQPRICELIST) report uses a new mass enabled pricing
Interface (PIQ_API) for pricing for several customers or materials at once. It does not involve a transactional
context anymore, but instead uses a new standalone pricing interface. This new pricing interface offers a similar
flexibility and extensibility as the existing transactional pricing interface.
Creation of price lists for customers also has to be flexible in terms of the structure of the result list and regarding
further processing options. Such possibilities for enhancements are available for the new report.

The price list creation is done in function module API_PIQ_SDPRICELIST. It offers the complete functionality like
the price list creation report SDPIQPRICELIST and can be used in customer projects as well. The API offers all
enhancement possibilities described in this document. Additionally there is a BAPI defined like the API for usage
when the price list creation should be triggered from a remote system, via remote function call.

1.1 API_PIQ_SDPRICELIST

API_PIQ_SDPRICELIST can be used whenever a price list should be generated from within an ABAP program and
an RFC call is not required.

1.1.1 Parameters

Importing
Parameters

IS_SELCRIT TYPE PIQS_SDPRICELIST_SELCRIT Selection Criteria for SD Price List

Parameters to Define Price List


IS_OUTPUT_FORMAT TYPE PIQS_SDPRICELIST_OUTPUT_PARAM Output

IS_CONTROL_DATA TYPE PIQS_SDPRICELIST_CONTROL Controlling data for SD Price List

IT_OUTPUT_FIELDS TYPE TDT_FIELDNAME Visible Fields for SD Price List

Parameter IS_SELCRIT contains the selection criteria. As a minimal set of selection criteria it is necessary to
pass a value for the sales area (VKORG/VTWEG/SPART) and a material and a customer. There are range table
parameters like MATNR, KUNNR. It is also possible to pass a list of materials and a list of customers in the
component MATNR_TAB and KUNNR_TAB. The user can either use the range table or the internal table format for
search.

CUSTOMER
© 2012 SAP AG. All rights reserved. 5
In case it is required to have further selection criteria, enter these values in component additional_selcrit. See
chapter Extensibility of Output and Selection Criteria for further information about extensibility of selection
criteria.
Parameter IS_OUTPUT_FORMAT controls how the price list should be processed, for example if it should be sent
by email.
Parameter IS_CONTROL_DATA contains parameters like language, price date, sales order type, a flag “delete zero
prices” and the structure KOMK_NAME_VALUE and KOMP_NAME_VALUE. This can be used in case the caller of the
API wants to pass pricing attributes to the pricing logic executed in the price list report. See chapter Extensibility
of Pricing Attributes for further information.
Optional Parameter IT_OUTPUT_FIELDS can be used in order to reduce the fields used for the price list output.
By default, the output uses the fields defined in the customizing tables (see chapter Extensibility of Output and
Selection Criteria ). In this table parameter you can pass a subset of fields from the customizing table, in case the
current price list should have fewer fields.

Exporting Parameters

TYPE
ER_RESULT REF TO DATA Result table

TYPE
ER_RESULT_LINE_TYPE REF TO CL_ABAP_STRUCTDESCR Runtime Type Services

TYPE
ER_RESULT_TABLE_TYPE REF TO CL_ABAP_TABLEDESCR Runtime Type Services

IF_PIQ_SDPRICELIST_
WRAPPER=>TDT_FIELD_
ET_FIELD_DESCRIPTION TYPE TXT Description for Output fields (labels)

EV_SUBRC TYPE SYSUBRC Return Code

Message log handle containing


EV_MSG_LOG_HNDL TYPE BALLOGHNDL messages emitted during processing

The price list result is returned in the dynamic parameter ER_RESULT. Metadata describing the type of the result
list is provided in parameter ER_RESULT_LINE_TYPE and ER_RESULT_TABLE_TYPE.
Parameter ET_FIELD_DESCRIPTION contain the description of the fields (field labels), as they can be defined as
well by customizing.
Parameter EV_MSG_LOG_HNDL returns a message log handle. The message log can be read using functions like
BAL_LOG_MSG_READ.

1.2 BAPI_PIQ_SDPRICELIST

The BAPI has two more importing parameters, which can be set to increase the price list creation performance.
IV_NO_INPUT_CHECK disables consistency checks for the input parameters. It should be used when the caller of
the BAPI can ensure that only consistent and correct selection criteria are used. When parameter
IV_ONLY_PRICING_RESULT is set, only the pricing result is returned. The result list is not enriched with material

CUSTOMER
© 2012 SAP AG. All rights reserved. 6
and customer related data and BAdi Method POST_PROCESSING and BAdI method PROCESS_OUTPUT is skipped
for performance reasons.
Furthermore, BAPI_PIQ_SDPRICELIST executes an authority check using authorization object PIQ_BAPI with
authority 01.

Importing
Parameters

IS_SELCRIT TYPE PIQS_SDPRICELIST_SELCRIT Selection Criteria for SD Price List

PIQS_SDPRICELIST_OUTPUT_ Parameters to Define SD Price


IS_OUTPUT_FORMAT TYPE PARAM List Output

IS_CONTROL_DATA TYPE PIQS_SDPRICELIST_CONTROL Controlling data for SD Price List

IT_OUTPUT_FIELDS TYPE TDT_FIELDNAME Visible Fields for SD Price List

IV_NO_INPUT_CHECK TYPE FLAG General Flag

IV_ONLY_PRICING_R
ESULT TYPE FLAG General Flag

The dynamic exporting parameter for the result list from PIQ_SDPRICELIST is mapped into static parameter
ET_PRICING_RESULT and ET_OUTPUT_EXTENSION. ET_PRICING_RESULT contains the result of the pricing API,
whereas ET_OUTPUT_EXTENSION contains the additional fields which the price list should contain and which are
maintained in customizing table PIQC_FIELD_LST_S / PIQC_FIELD_LST_C.
In order to enable the BAPI to copy the output fields from customizing table PIQC_FIELD_LST_C to parameter
ET_OUTPUT_EXTENSION, you must execute function module PIQ_GEN_OUTPUT_STRUCT in the target
system/target client with DDIC change authority. The system generates a DDIC structure
(PIQS_OUTPUT_EXTENSION_CLNT*), which is used by the BAPI for mapping the custom output fields.

Exporting Parameters

ET_PRICING_RESULT TYPE PIQT_SDPRICELIST_RES_HEAD SD Price List: Pricing Result Header

Fields defined in
ET_OUTPUT_EXTENSION TYPE BAPIPAREXTAB PIQC_FIELD_LST_S(_C)

ET_MESSAGE TYPE BAPIRETTAB Return parameter table

EV_SUBRC TYPE SYSUBRC Return Code

CUSTOMER
© 2012 SAP AG. All rights reserved. 7
2 Enhancements of the Price list report

The price list creation functionality can be enhanced in several ways. It is possible to add new selection criteria.
Changes to the price list result structure (new or different fields) can be easily added in Customizing.
Additionally, BAdIs provide the possibility to influence the customers and materials for which the price list is
created. The result of the pricing call can be modified by a BAdI and additional types of output processing for the
list can be implemented.

2.1 Extensibility of Output and Selection Criteria

During price list creation, customer related data and material related data is collected from the master data
tables, which is needed for the execution of pricing and which is needed for enriching the price list result table.
This is done in two SQL select statements: one for the customer related data and one for the material related
data. These SQL selects take into account the selection criteria and the fields necessary for pricing and the result
list.
In order to provide a maximum of flexibility, the fields for the pricing result list can be customized. Three
customizing tables are provided. For each table, one Customizing activity is provided for the SAP standard
delivery and one for custom-defined entries.

2.1.1 Customizing Table PIQC_TABMETADT_S /


PIQC_TABMETADT_C

This table describes the metadata used for joining master data tables to the customer table KNVV or to the
material table MVKE. It describes which key field from the target table is joined to which source field from the

CUSTOMER
© 2012 SAP AG. All rights reserved. 8
source table. Additionally constant values can be defined or a table can be joined taking into account the
language.
PIQC_TABMETADT_S contains the entries from the SAP standard deliveries. Custom-defined entries should be
done in the customizing table PIQC_TABMETADT_C.
Example:
The system should display the language dependent material description from table MAKT. The SQL table-join uses
table/field MVKE-MATNR which is joined to MAKT-MATNR. Additionally MAKT-SPRAS (language) is part of the join, it
gets filled by the system with the current language.

2.1.2 Customizing Table PIQC_FIELD_LST_S /


PIQC_FIELD_LST_C

Customizing Table PIQC_FIELD_LST_S / PIQC_FIELD_LST_C controls the following:


- fields which have to be read from the database for filling the price list result table
- fields which should be displayed in the price list result table fields used as selection criteria
- fields which should not be displayed in the standard output
- fields which are filled in the price list layer and passed as price attributes to the pricing function
Fields which have flag ‘Output’ set are added to the price list result table. Those can be fields which are read from
material master data, customer master data, which are taken from the pricing result function or which are filled by
using BAdI BADI_PIQ_SDPRICELIST method PROCESS_RESULT. Fields which use source table KOMK or KOMP
are taken from the result of the pricing call result function, they should use entry “C Pricing” in field “Select”.

2.1.3 Customizing Table PIQC_DB_ALIAS_S/


PIQC_DB_ALIAS_C

It is not directly the table name for the definition of the SQL join condition used but a table alias. Using this alias
definition, it is possible to define several join conditions to the same table.

CUSTOMER
© 2012 SAP AG. All rights reserved. 9
2.2 Extensibility of Pricing Attributes

Price Attributes are fields whose values influence the pricing. During condition access in the core pricing logic, this
data is needed for accessing the single condition table records. For example, a condition from condition table
A030 requires (among others) the field KONDM (material pricing group) to be filled. These price attributes are
usually determined in the price inquiry APIs which are used by the SD price list. However, since this price attribute
is already preset on the selection screen, the system can pass this value to the underlying pricing interface. This
field has therefore ‘Source Type’ as ‘Item Caller Data’ in the Customizing table PIQC_PREP_FLD_S. In
Customizing table PIQC_FIELD_LST_S, an entry exists for field kondm saying from which table field the kondm
value should be read.
You can add other search criteria into price list search screen using enhancement point
ES_PIQ_SDPRICELIST_EXT3. Its value can be passed to the price list API by using ABAP macro
transfer_select_option in ES_PIQ_SDPRICELISR_EXT6. This field value can also be passed to the pricing
core using similar customizing as described below.

An entry in the price list Customizing ( table PIQC_FIELD_LST_C ) is required because it has to be specified
from which master data table the value should be read and if the table can be accessed when the material data is
selected or when the customer data is selected .
In such cases, the price attribute in the Customizing table PIQC_PREP_FLD_C/ PIQC_PREP_FLD_S has to have
“Source Type” set to “Global Caller Data”, “Head Caller Data”, or “Item Caller Data” . Additionally, the price list
report has to know that it has to fill this price attribute. Therefore, an entry in Customizing table
PIQC_DB_ALIAS_S/ PIQC_DB_ALIAS_C has to be made as well, specifying Field Name, Source Table / Source
Field /Table Alias and the type of Select .
Another use case is for some special KOMK/KOMP fields. Pricing inquiry accepts the pricing procedure (KALSM),
document procedure (KALVG), local currency (HWAER) as global parameter, item category (PSTYV), quantity
(MGAME) as item attributes. If these values are fixed values for price lists creation, they can be added to the UI
using enhancement spot ES_PIQ_SDPRICELIST_EXT4. The values can be passed to pricing by
ES_PIQ_SDPRIRCELIT_EXT6 using macro ADD_NAME_VALUE (coding example
add_name_value 'KALSM' kalsm 'KOMK'.) In pricing core, these values will be used for this price list. No further
Customizing table entries are required for this special case.

CUSTOMER
© 2012 SAP AG. All rights reserved. 10
2.3 Enhancement Points in Transaction V_NLN / Report
SDPIQPRICELIST

The following enhancement points provide possibilities for enhancements in the price list report:
ES_PIQ_SDPRICELIST_EXT1
You can use this enhancement point when you want to add a selection field to the section for customer data.

ES_PIQ_SDPRICELIST_EXT2
You can use this enhancement point when you want to add a selection field to the section for material master
data. For example, if you want to add the material group as a selection field, you insert the following statement at
this enhancement point:
SELECT-OPTIONS: matkl FOR mara-matkl

ES_PIQ_SDPRICELIST_EXT3
You can use this enhancement point when you want to add a field to the section for control data. For example, if
you want to add the pricing procedure as a pricing attribute field to the control data, you insert the following
statement at this enhancement point:
parameters: kalsm type kalsm_d

ES_PIQ_SDPRICELIST_EXT4
You can use this enhancement point when you want to add a field to the section for price list output.

ES_PIQ_SDPRICELIST_EXT5
You can use this enhancement point when you want to add your own section to the UI for transferring data to the
price list creation API.

ES_PIQ_SDPRICELIST_EXT6
You can use this enhancement point to transfer your fields to the pricing API. For example, given the previous
example for extension point ES_PIQ_SDPRICELIST_EXT2, you insert the following statement at enhancement
point ES_PIQ_SDPRICELIST_EXT6:
transfer_select_option 'MARA' 'MATKL' matkl
Given the previous example for enhancement point ES_PIQ_SDPRICELIST_EXT3, you insert the following
statement at enhancement point ES_PIQ_SDPRICELIST_EXT6:
add_name_value 'KALSM' kalsm 'KOMK'

CUSTOMER
© 2012 SAP AG. All rights reserved. 11
2.4 BAdIs

In the enhancement spot ES_PIQ_SDPRICELIST_API the two BAdIs BADI_PIQ_SDPRICELIST and


BADI_PIQ_SDPRICELIST_OUTPUT exist . They can be used to influence the behavior of the price list creation
process.

2.4.1 BADI_PIQ_SDPRICELIST

Method GET_CUSTOMER_DATA / Method GET_MATERIAL_DATA


Before the price list is calculated, the internal program flow creates a list of materials and customers for which the
price list is created. These lists already contain customer dependent and material dependent fields which are
required in the price list result output table.
These BAdIs provide the possibility to modify the customer and material data. For example, you can exclude
customers / materials from the price list creation or add further customers / materials.
The customer / material data table structure is dynamic. For convenience reasons, the type of the structure is
provided in parameter IR_RESULT_TABLE_TYPE.

Method PREPARE_PRICING
This BAdI method is executed before the pricing is done. It can be used for making changes to the control data of
the pricing call and for modifying the pricing attributes. These are passed with the parameters cs_global ,
cs_head and cs_item, depending if the attribute is relevant for all price lists, or if it is on customer level or if it is on
material level.

Method PROCESS_RESULT
BAdI method PROCESS_RESULT is called after the price list has been calculated. It can be used to influence the
calculated price lists before they are processed for output. You can do changes to the price list result table and to
the field labels of the result structure.

CUSTOMER
© 2012 SAP AG. All rights reserved. 12
2.4.2 BADI_PIQ_SDPRICELIST_OUTPUT

Method PROCESS_OUTPUT
This method can be used to define own processing steps of the price list result. SAP provides a standard
implementation of this BAdI method which sends the price list result via email to a mail recipient. Possible
implementations on customer project basis could be for example to put the individual price lists to an FTP server.
Parameters:

IS_OUTPUT_FORMAT SAP structure which defines the processing option

SAP Structure which passes data like pricing data, sales document type,
IS_CONTROL_DATA
language, pricing attribute structures and others

IR_RESULT Dynamic table parameter which holds the price list result

IR_RESULT_LINE_TYPE ABAP Structure descriptor which describes the type of the result parameter

IT_CUSTOMERS List of customer numbers for which the price lists has been generated

IT_FIELD_DESCRIPTION Field labels of the result structure, as described in IMG customizing (table
PIQC_FIELD_TXT_C / PIQC_FIELD_TXT_S)

Handle for the BAL Message log. The messages can be retrieved from the log
IV_MESSAGE_LOG using BAL_LOG_MSG_READ. New messages can be added with function
BAL_LOG_MSG_ADD.

CUSTOMER
© 2012 SAP AG. All rights reserved. 13
3 Enhancements in the Price Inquiry API

The price inquiry API offers the possibility to execute a pricing for several materials and for several customers in
one single step. It is optimized for mass transactions like the SD price list.
When pricing should be executed for a material/customer combination, the system requires some data (pricing
attributes) which are needed in order to access the correct pricing condition tables. As this price inquiry API does
not use a SD sales order simulation or does not simulate an SD invoice, there is customizing necessary to define
the sources for the filling of the price attributes.
This filling of the pricing attributes is a major step in customizing. When the defined pricing procedure uses
customer individual fields in the condition access, the mapping for these pricing attributes has to be defined. SAP
delivers the settings for the standard pricing attributes in the customizing tables of the price inquiry API. For
individual customer defined price attributes, these settings have to be made in Customizing activity "Define
Sources for Pricing Communication Structures".
If the filling of the price attribute requires a more complex logic which cannot be easily modeled in the
Customizing activity, there is BAdI BADI_PIQ_PREPARE (enhancement spot ES_PIQ_PREPARE).

3.1 Mapping of Pricing Attributes

For the standard set of pricing attributes the mapping information is already available.
This mapping is visible in Customizing under Sales & Distribution -> Basic Functions -> Pricing -> Price Lists ->
Price Inquiry ->Define Sources for Pricing Communication Structures (Display Standard Sources). In the same
Customizing node you can define additional sources for pricing communication structure fields.
You usually have to add additional sources when you use own communication structure fields (structure KOMK
and KOMP, or KOMKAZ and KOMPAZ) in pricing routines from transaction VOFM or userexits in pricing which
utilize these additional fields. This is needed in order to make the Price Inquiry API recognize the fields used by

CUSTOMER
© 2012 SAP AG. All rights reserved. 14
you and to give further information how these fields should be filled during a pricing execution in the Price Inquiry
API layer.

3.1.1 Identifying Fields Used in Own Pricing Enhancements

As a help for finding out which additional fields are used, there is the report VFPRCCUERATTR which can be
accessed in Customizing under Sales & Distribution -> Basic Functions -> Pricing -> Price Lists -> Price Inquiry-
>Edit Fields Used in Pricing Enhancements.
This report does a scan over the coding used in pricing user exits and pricing routines (transaction VOFM). It
scans pricing requirements, scale base formulas, condition base formulas, condition value formulas and group
key routines. Additionally, you can browse into the routines and userexit in order to find out what fields are used.

3.2 BAdI BADI_PIQ_PREPARE

3.2.1 Method ADAPT_HEAD_ITEM_DATA

Using this BAdI method it is possible to adapt the head and item data.

3.2.2 Method ADAPT_KOMK_KOMP_DATA

Using this BAdI Method it is possible to adapt pricing attributes in the pricing communication structure KOMK and
KOMP before the pricing is executed .

CUSTOMER
© 2012 SAP AG. All rights reserved. 15
4 Example

4.1 Scenario

In the customer master, the field "Customer Group 1" (KNVV- KVGR1) is used to assign customers to specific
customer group values. This attribute is required to function as a selection field in the price list report and it also is
used in the pricing itself to determine discounts.
It is described here how the price list report and the price inquiry API has to be enhanced.

4.2 Assumptions

We assume that the scenario is already working in the pricing during sales order entry. Here we describe the
additional steps necessary for enhancing the price list report.
In detail, this means you already have done the following:
- Enhanced pricing structure KOMKAZ with the field ZZKVGR1
- Enhanced the field catalog for pricing in sales
- Created a condition table containing field ZZKVGR1
- Created an appropriate access sequence
- Created an appropriate condition type
- Included the condition type into the used pricing procedure
- Have maintained the price condition master data

CUSTOMER
© 2012 SAP AG. All rights reserved. 16
4.3 Enhancing the Price List Report

4.3.1 Adding a Field as a Selection Criteria

You must first add the field to the customer specific fields of the price list report in Customizing under Sales and
Distribution -> Basic Functions -> Pricing -> Price Lists -> Selection and Result -> Define Fields.

Additionally, the report SDPIQPRICELIST, which represents transaction V_NLN, has to be enhanced in order to
show the field as a selection criterion. For this purpose, you add the select-option statement to enhancement
point ES_PIQ_SDPRICELIST_EXT1.

REPORT sdpiqpricelist.

* Data defintion for new SD price list


INCLUDE sd_piq_pl_data_i01.

* UI Part 1) Sales area block (standard)


INCLUDE sd_piq_pl_sel_i01.

* UI Part 2) Customer Block (standard plus customer enhancement )


SELECTION-SCREEN BEGIN OF BLOCK customer WITH FRAME TITLE text-a02.
SELECT-OPTIONS: s_kunnr FOR knvv-kunnr .
* Customer extension: further criteria to search for business partners
ENHANCEMENT-POINT ES_PIQ_SDPRICELIST_EXT1 SPOTS ES_PIQ_SDPRICELIST STATIC .
*$*$-Start: ES_PIQ_SDPRICELIST_EXT1--------------------------------------------------
-----------$*$*
ENHANCEMENT 1 ZKVGR1. "active version
SELECT-OPTIONS: kvgr1 for knvv-kvgr1.
ENDENHANCEMENT.
*$*$-End: ES_PIQ_SDPRICELIST_EXT1--------------------------------------------------
-----------$*$*
SELECTION-SCREEN END OF BLOCK customer.

CUSTOMER
© 2012 SAP AG. All rights reserved. 17
Now the field from the report user interface has to be linked to the underlying business logic as a selection option.
This is done using the statement "transfer_select_option" in the enhancement point
ES_PIQ_SDPRICELIST_EXT6.

REPORT sdpiqpricelist.


START-OF-SELECTION.

* transfer the standard search critiera to API


INCLUDE sd_piq_pl_main_map_i04.
ENHANCEMENT-POINT ES_PIQ_SDPRICELIST_EXT6 SPOTS ES_PIQ_SDPRICELIST .
*$*$-Start: ES_PIQ_SDPRICELIST_EXT6---------------------------------------------
----------------$*$*
ENHANCEMENT 2 ZKVGR1. "active version
transfer_select_option 'KNVV' 'KVGR1' kvgr1.
ENDENHANCEMENT.
*$*$-End: ES_PIQ_SDPRICELIST_EXT6---------------------------------------------
----------------$*$*

* check the required business function and switch is activated


IF cl_sd_617_switch_check=>sd_sfws_price_list( ) IS INITIAL.
MESSAGE s015(cm_piq_sdpricelist) WITH 'SD_SFWS_PRICE_LIST' DISPLAY LIKE 'E'.
RETURN.
ENDIF.

4.3.2 Adding the Field in the Output Table

The field is added to the output table by simply making sure that the following entry (from the customizing done in
chapter Adding a Field as a Selection Criteria) has flag "Output" set.

CUSTOMER
© 2012 SAP AG. All rights reserved. 18
4.4 Enhancing Price Inquiry API

In order to have the price inquiry API read the field for the selected sold-to parties , add the following entry to the
Customizing table PIQC_PREP_FLD_C in Customizing under Sales and Distribution -> Basic Functions -> Pricing -
> Price Lists -> Price Inquiry -> Define Sources for Communication Structures.

Source type "Database Table Alias" specifies that the price inquiry API should read the field value from
sourcetable/source field KNVV-KVGR1 . It also would be possible to read the value in the price list selection layer
(see chapter Enhancing the Price List Report) and to pass the value into the Price Inquiry API. This could be done
with source type "Head Caller Data".

CUSTOMER
© 2012 SAP AG. All rights reserved. 19
www.sap.com/contactsap

Material Number

© 2012 SAP AG. All rights reserved.


No part of this publication may be reproduced or transmitted in any
form or for any purpose without the express permission of SAP AG.
The information contained herein may be changed without prior
notice.
Some software products marketed by SAP AG and its distributors
contain proprietary software components of other software
vendors.
Microsoft, Windows, Excel, Outlook, and PowerPoint are registered
trademarks of Microsoft Corporation.
IBM, DB2, DB2 Universal Database, System ads, System i5, System
p, System p5, System x, System z, System z10, System z9, z10, z9,
iSeries, pSeries, xSeries, zSeries, eServer, z/VM, z/OS, i5/OS,
S/390, OS/390, OS/400, AS/400, S/390 Parallel Enterprise
Server, PowerVM, Power Architecture, POWER6+, POWER6,
POWER5+, POWER5, POWER, OpenPower, PowerPC, BatchPipes,
BladeCenter, System Storage, GPFS, HACMP, RETAIN, DB2
Connect, RACF, Redbooks, OS/2, Parallel Sysplex, MVS/ESA, AIX,
Intelligent Miner, WebSphere, Netfinity, Tivoli and Informix are
trademarks or registered trademarks of IBM Corporation.
Linux is the registered trademark of Linus Torvalds in the U.S. and
other countries.
Adobe, the Adobe logo, Acrobat, PostScript, and Reader are either
trademarks or registered trademarks of Adobe Systems
Incorporated in the United States and/or other countries.
Oracle is a registered trademark of Oracle Corporation.
UNIX, X/Open, OSF/1, and Motif are registered trademarks of the
Open Group.
Citrix, ICA, Program Neighborhood, MetaFrame, WinFrame,
VideoFrame, and MultiWin are trademarks or registered trademarks
of Citrix Systems, Inc.
HTML, XML, XHTML and W3C are trademarks or registered
trademarks of W3C®, World Wide Web Consortium, Massachusetts
Institute of Technology.
Java is a registered trademark of Sun Microsystems, Inc.
JavaScript is a registered trademark of Sun Microsystems, Inc.,
used under license for technology invented and implemented by
Netscape.
SAP, R/3, xApps, xApp, SAP NetWeaver, Duet, PartnerEdge,
ByDesign, SAP Business ByDesign, and other SAP products and
services mentioned herein as well as their respective logos are
trademarks or registered trademarks of SAP AG in Germany and in
several other countries all over the world. All other product and
service names mentioned are the trademarks of their respective
companies. Data contained in this document serves informational
purposes only. National product specifications may vary.
These materials are subject to change without notice. These
materials are provided by SAP AG and its affiliated companies ("SAP
Group") for informational purposes only, without representation or
warranty of any kind, and SAP Group shall not be liable for errors or
omissions with respect to the materials. The only warranties for SAP
Group products and services are those that are set forth in the
express warranty statements accompanying such products and
services, if any. Nothing herein should be construed as constituting
an additional warranty.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy