Application Development 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: 

Sales order. ImP

former_member588853
Active Contributor
0 Kudos

Hello,

we are getting all the order which are not rejected look at the statement below

SELECT vbap~vbeln

vbap~posnr

vbap~erdat

vbap~kzwi2

vbak~auart

vbak~kunnr

vbak~vkorg

vbak~vtweg

vbak~spart

INTO TABLE p_it_salesorders

FROM vbap INNER JOIN vbak

ON vbapvbeln = vbakvbeln

WHERE vbap~erdat BETWEEN l_ytddate AND p_last_date

AND ( vbak~auart = 'ZCR'

OR vbak~auart = 'ZOR'

OR vbak~auart = 'ZDR'

OR vbak~auart = 'ZKE'

OR vbak~auart = 'ZRP'

OR vbak~auart = 'ZRE' )

AND vbap~abgru EQ space.

And doing some calculations and showing the output in AVL..

I got a modified spec , the point is stated below:

NEW Spec point: Change the output so that it shows the Shipped $ values only (Order lines which are invoiced / Partially invoiced)

How do we get lines which are shipped( invoiced/partially invoiced.

may be we need to check in VBUk table.. donno exactly.. help me out..

regards,

nazeer

Edited by: N a z e e r on Oct 16, 2008 5:59 PM

Edited by: N a z e e r on Oct 16, 2008 6:12 PM

Edited by: N a z e e r on Oct 16, 2008 6:13 PM

4 REPLIES 4

Former Member
0 Kudos

Hello,

Check with you functional team. I guess the tables to look at VBUK and VBUP. not sure though.

regards,

Advait

0 Kudos

I fund we need to check in VBUP table for line items,

invoiced GBSTa = 'C'

partially invoice GBSTA = "B'

Please let me know if correct..

0 Kudos

I would say VBUP-FKSTA

A Not yet processed

B Partially processed

C Completely processed

regards,

Advait

Former Member
0 Kudos

hi

for overall rejection status check the field in VBUK-ABSTK.

blank Not Relevant

A Not yet processed

B Partially processed

C Completely processed