cancel
Showing results for 
Search instead for 
Did you mean: 

To get Pricing Condition from Delivary weither it is SO or PO

mohan_irla
Explorer
0 Kudos
199

Hi All!

I have to calculate rebate for each line item in vl02n.

now this i calculate in

BADI: LE_SHP_DELIVERY_PRO

Method: CHANGE_DELIVERY_ITEM

and rebate calculation for entire Document i calculate in

Method: SAVE_DOCUMENT_PREPARE

where i get Current Status of Delivery Items in CT_XLIPS

uptill now it is ok.

i am not getting condition document number

in this delivary or any other function module to get pricing condition i.e. can i get KNUMV of table KONV in current structure of XLIPS

Now in XLIPS i have VGBEL which give me

SO Number(VBAK-VBELN) i get condition document number (VBAK-KNUMV) and from this i will get different condition types from KONV table, but this entire logic fails when i go for inter-company orders (Purchase order) over here i have to go to the EKKO table for KNUMV.

please can give some solution.

regards,

mohan

Accepted Solutions (0)

Answers (2)

Answers (2)

mohan_irla
Explorer
0 Kudos

hi Prabhu,

thanks, yes result is ok

now i can get the condition Documents from VBAK/EKKO

accourdingly, thanks a lot.

regards

mohan

Former Member
0 Kudos

Hi Mohan ,

try to make use of VGTYP , i think by using this field value u can put ur logic.

VGTYP = C Sales Order

= V Purchase Order.

Regards

Prabhu

Former Member
0 Kudos

Hi Mohan,

You Can use Document Flow table<b> VBFA</b> to find the Purcahse Order / Sales Order of the Delivery using the Document Category <b>VBTYP_N</b>.

VBFA-VBTYP_N = C yields the Sales Order Number.

VBFA-VBTYP_N = V yields the Purchase Order Number.

From the Sales Order Or Purchase order You can fetch the corresponding Condition Type.

Regards,

Baburaj