Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

pricing routine

Vijay
Active Contributor
0 Likes
353

hi

i want to know how the pricing routines work ??

please provide some sample code if posible.

regards

vijay

2 REPLIES 2
Read only

Former Member
0 Likes
311

recently i created a pricing routinue in SD...

routinue number 947 from VOFM-->Pricing....

Code written is as follows...

FORM KOBED_947.

*{ INSERT D81K926007 1

----


  • Notes : This routine is used to exclude Freight charge ZHFA for

  • service materials. Whenever material master document ZA5 is

  • specified then ZHFA on the material should not be applied

  • in the sales order.

constants: c_za5 like drad-dokar value 'ZA5',

c_mara like drad-dokob value 'MARA'.

data:l_dokar like drad-dokar. " Document Type

sy-subrc = 4.

clear: l_dokar.

  • Checking value of Document type from DRAD for the conditions of the

  • material specified in the sales order.

SELECT single dokar

INTO l_dokar

FROM drad

WHERE dokar eq c_za5

AND dokob EQ c_mara

AND objky EQ komp-matnr.

  • When there is no entry sy-subrc is set to value 4

if sy-subrc is initial.

sy-subrc = 4.

else.

  • When there is a entry sy-subrc is set to value 0

sy-subrc = 0.

endif.

*} INSERT

ENDFORM.

FORM KOBEV_947.

ENDFORM.

Read only

Vijay
Active Contributor
0 Likes
311

hi

can u please how can i pick values entered on screen in pricing routine?