RE:[sap-log-sd] One Condition only
Posted by
Admin at
Share this post:
|
on 07/15/2009 10:33:00 AM
Hi Asad,
it is may be too late, but I had exactely same problem , and I get solution - customer condition routine to be assigned in the pricing schema to each condition. ZMO1 is obligatory in the pricing schema, ZMO2 not.
If ZMO2 exist, then ZMO1 will be set as not obligatory .
data: l_kschl_1 type kschl.
data: l_kschl_2 type kschl.
l_kschl_1 = 'ZMO1'.
l_kschl_2 = 'ZMO2'.
if xkomv-kschl = l_kschl_2.
read TABLE tobli with table key kschl = l_kschl_1
TRANSPORTING NO FIELDS.
if sy-subrc = 0.
delete table tobli with table key kschl = l_kschl_1.
endif.
read TABLE tobli with key kschl = l_kschl_2
TRANSPORTING NO FIELDS.
if sy-subrc <> 0.
tobli-kschl = l_kschl_2.
append tobli.
sy-subrc = 0.
endif.
endif.
best regards
Natalia __.____._
Toolbox.com
4343 N. Scottsdale Road
Suite 280
Scottsdale, AZ 85251
In the Spotlight