cancel
Showing results for 
Search instead for 
Did you mean: 

Adding fields to the field catalogue for pricing

Former Member
0 Kudos

Is there a way to add a field from the material master classification to the field catalogue for the access sequence for pricing?

I have created a test field in the material classification view:

Merchandise Code with value = 4000

I want to create an access sequence for condition type ZXXX

The sequence would be :

Sales Org/Merchandise Code

1001 4000

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

If the field catalog is extended to include a new field, the new field is not available in the definition of condition tables or the definition of access sequences.

The allowed fields for conditions and access sequences are defined in the tables KOMG, KOMK and KOMP.

The fields in tables KOMK and KOMP can be used for the definition of access sequences, and the fields of table KOMG as key fields for condition tables. A field which is taken up into the field catalog from tables KOMK or KOMP is ONLY valid as the definition of access sequences and NOT as a key field for condition tables, therefore it does not appear in the selection list of condition key field.

Check whether desired the selection of condition records can be reached using the definition of an access sequence.

For example, different condition records can be selected according to the ship-to party (although the ship-to party field only appears in the KOMK field and is therefore not available as a key field for condition tables), so that condition records are created which contain the customer number as a key field and also have an access sequence which allocates the ship-to party field to the the customer number field. If there is no suitable field in tables KOMK, KOMP or KOMG, see the 'system modification' section of SD Customizing.

For ex:

You want to use the field PSTYV (Sales Document Item Category) that is contained in the structure KOMP (Communication Item Pricing) as a key for a condition table.

However, when you create a condition table (transaction V/03), the system does not propose the field in the field catalog.

For technical reasons, the field PSTYV was included in the structure KOMP, but not in the structure KOMG (Allowed Fields for Condition Structures).

To solve the problem, proceed as follows:

1. Call the ABAP Dictionary (transaction SE11) and create the data type ZZPSTYV. Select PSTYV as the domain. As the short description, you can use 'ZZ - Sales Document Item Category' (for example) and as the field labels, you can use the field labels of the data type PSTYV. Save, check and activate your entries.

2. In the ABAP Dictionary (transaction SE11), enter the structure KOMPAZ, switch to change mode and make the following entries:

Component Component type

ZZPSTYV ZZPSTYV

Save, check and activate the change.

3. Note: Due to the changes in the structure KOMPAZ, the field ZZPSTYV is now known in the structures KOMG and KOMP because the structure KOMPAZ is included in both structures.

4. Call transaction SPRO. Go to 'Sales and Distribution > Basic Functions > Pricing > Pricing Control' and execute 'Define Condition Tables'.

Select 'Conditions: Allowed fields' and enter 'ZZPSTYV' as a new entry.

5. Note: When you create the condition table Annn, you can now use the field ZZPSTYV as a key field.

6. Populate the new field you defined by including the following source code line in the user exit USEREXIT_PRICING_PREPARE_TKOMP:

MOVE xxxx-PSTYV TO TKOMP-ZZPSTYV.

In order processing, the user exit is available in the include MV45AFZZ, and in billing document processing, it is available in the include RV60AFZZ.

Note that you can also use this note as a reference if you want to use other customer-specific fields as key fields in a condition table. For header fields, use the structure KOMKAZ instead of the structure KOMPAZ, and use the user exit USEREXIT_PRICING_PREPARE_TKOMK instead of the user exit USEREXIT_PRICING_PREPARE_TKOMP.

Regards,

Saju.S

Former Member
0 Kudos

Thanks Saju.......

I understand that process now but can I add fields from the material classification to ZZPSTYV?

I know you mentioned it can be used to add customer defined fields but does it include material master classification view fields?

Edited by: Saad Ali Siddiqui on Jul 22, 2011 4:51 PM