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

ABAP query-Quantity contract

Shiva_Ram
Active Contributor
0 Likes
588

Hi,

How to get the values for the "order quantity" from the field RV45A-KWMENG. I tried to extract from VBAP-KWMENG but of no avail. Is there any FM to fetch the values from quantity contracts?

I appreciate your response.

Thanks in advance.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
500

Hi!

Do you try to get cumulative quantity of all reference orders for contract? If so then use select:

SELECT SINGLE SUM( rfmng )

INTO rfmng_val

FROM vbfa

WHERE vbelv = contract_vbeln

AND posnv = contract_posnr

AND vbtyp_n = 'C'.

rfmng_val is cumulative quantity in base unit of measure.

Then just convert it into corresponding contract sales unit of measure.

Regards,

Maxim.

2 REPLIES 2
Read only

Former Member
0 Likes
501

Hi!

Do you try to get cumulative quantity of all reference orders for contract? If so then use select:

SELECT SINGLE SUM( rfmng )

INTO rfmng_val

FROM vbfa

WHERE vbelv = contract_vbeln

AND posnv = contract_posnr

AND vbtyp_n = 'C'.

rfmng_val is cumulative quantity in base unit of measure.

Then just convert it into corresponding contract sales unit of measure.

Regards,

Maxim.

Read only

0 Likes
500

Hi Maxim Polonevich,

Thank you so much. This time too it worked well.

With regards,

Shiva