cancel
Showing results for 
Search instead for 
Did you mean: 

Pricing using custom table instead of using condition records

Former Member
0 Kudos

Hi,

Does any one have any experience with pricing using a custom table which would receive condition records from an extrenal interface instead of using the routine condition technique for calculating discounts ?

~A

Edited by: adityapd on Mar 15, 2010 12:22 AM

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

we used it once to determine the value of condition VPRS. So we defined a formula (VOFM) to calculate this value in the price determination for the condition we needed (column AltCty).

Here is the code used:

FORM FRM_KONDI_WERT_999.

tables zzz_conds.

*{ INSERT CSDK952275 1

data zzzbal like zzz_conds occurs 0 with header line.

data: w_komk_belnr like komk-belnr.

clear w_komk_belnr.

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'

EXPORTING

INPUT = komk-belnr

IMPORTING

OUTPUT = w_komk_belnr.

clear zzz_conds.

select single * into zzzbal from zzz_conds

where ZZKONV_knumv = w_komk_belnr

and ZZKONV_kposn = komp-kposn

and ZZKONV_kschl = 'VPRS'.

if sy-subrc = 0.

xkwert = zzzbal-ZZKONV_kbetr.

xkomv-kbetr = zzzbal-ZZKONV_kbetr.

xkomv-kwert = zzzbal-zzkonv_kwert.

endif.

*} INSERT

ENDFORM.

table zzz_conds had the following structure:

MAND

ZZ-KONV-KNUMV

ZZ-KONV-KPOSN

ZZ-KONV-KSCHL

ZZ-KONV-KBETR

ZZ-KONV-KWERT

Hope this helps.

Regards,

Joan

Former Member
0 Kudos

Hi,

What do you mean by price determination using external condition table? What is the exact requirement? If you can explain the requirement, we might be able to give an answer on how to map is using SAP.

If you want to enter price at sales order creation, what you can do is, set the condition type as "Manual Entry has Priority"

Then use a user exit to pass the price to the relevant condition record using your Z table.

Appreciate if you can give the exact requirement.

Thanks and best regards,

Anupa

Former Member
0 Kudos

Thanks Anupa and Agis for your quick responses.

Here are the brief requirements :

1) Some part of the data required for calculating the discounts applicable for a particular customer is received from an external interface and stored in a custom table.

2) Discount applicable for a particular customer is calculated based on this data received from the interface as well as some other conditions which could entered either in the form of condition records or stored in the same custom table which receives data from the external interface.

Was wondering what would be the best approach

~A

Former Member
0 Kudos

Hi,

Let's get one by one.

>1) Some part of the data required for calculating the discounts applicable for a particular customer is received from an external interface and stored in a custom table.

Do you have a predefined logic for those discount. I mean how do you determine those discounts. Based on what? Based on Material he has ordered, Customer, etc. If you can finalize such a method, what you have to do is, create condition table for all those logic. Then give those formats to the customer and ask him to send it according to your format. Then from the third party interface code it to store in the relevant table.

When creating sales order, you can retrieve that for the sales order as the discount.

>2) Discount applicable for a particular customer is calculated based on this data received from the interface as well as some other conditions which could entered either in the form of condition records or stored in the same custom table which receives data from the external interface.

As I mentioned, this can be the validity date (Valid From Date) of the condition. Then you can determine the relevant condition as per your requirement.

Then do pricing configuration to pick the relevant discount amount at the sales order entry.

Thanks and best regards,

Anupa

Former Member
0 Kudos

Hi,

Does any one have any experience with pricing using a custom table which would receive condition records from an extrenal interface instead of using the routine condition technique for calculating discounts ?

~A

Edited by: adityapd on Mar 15, 2010 12:22 AM

Can you explain the requirement a bit more? You want the interface to make condition records or make the pricing in the sales order? In the second case I guess you can easily set an interface that during SO creation will fill the values in "manual" conditions in the pricing procedure .