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

Function Module for Documetn Flow Reading

Former Member
0 Likes
1,824

Hello,

I have requirement to read the document flow of a sales document.

Actually i am using a select statement for the table VBFA. But then it is taking a very long time the performance is very bad.

I remember having used a fucntion module some time before but cant recall the name.

Kindly let me know if anyone of you know which is the function module to read the document flow of a sales document.

Thankyou.

8 REPLIES 8
Read only

Former Member
0 Likes
951

Dear Brijesh,

You explain your correct requirement, and i shall say you which tables to use for the correct link and faster performance.

regards

Lakshminarayanan

Read only

0 Likes
951

Hi Lakshminarayan,

The exact requirement is to fetch the shipment number i.e Shipment notfication number.

I have the delivery as the input, one more issue here is that for the delivery there would be a select option so if no select option then all the deliveries would be considered.

this is the code i have written

DATA : BEGIN OF g_t_tknum OCCURS 0,

vbelv LIKE likp-vbeln,

vbeln LIKE vttk-tknum,

shtyp LIKE vttk-shtyp,

END OF g_t_tknum.

SELECT vbelv vbeln

INTO CORRESPONDING FIELDS OF TABLE g_t_tknum

FROM vbfa

WHERE vbelv IN s_vbeln

AND posnv = '000000'

AND vbtyp_n = '8'

AND vbtyp_v = 'J'.

Read only

0 Likes
951

See for getting the shipment document against a delivery no, you can go to table VTTP, pass the delivery no into the field VTTP-VBELN.

You can get the shipment document.

For getting the transportation planning point plant you can put a join against VTTK and VTTP and get the field vttk-tplst. This field is same as the plant where order/delivery/invoice has been issued.

Hope this solves your issue.

Lakshminarayanan

Message was edited by: Lakshminarayanan Jagannathan

Read only

0 Likes
951

Please rewars my first points if you got the solution right.

Read only

0 Likes
951

Thankyou,

i was not aware of this will keep it in mind from next time to rewaard the points.

Read only

vinod_gunaware2
Active Contributor
0 Likes
951

<b>RV_ORDER_FLOW_INFORMATION </b> Reads sales document flow of sales document after delivery and billing

Don't forget also check direct reference documents for the both starting document # and preceding/following document types that you are searching for (For example, if you search delivery for the given SO, check also LIPS-VGBEL and LIPS-VGPOS, if it's possible with regard to performance).

regards

vinod

Read only

Former Member
0 Likes
951

Hi,

check these FM's <b>RV_FLOW</b>

<b> RV_ORDER_FLOW_INFORMATION </b>

Regards

vijay

Read only

Former Member
0 Likes
951

Hello Thanks a lot for all your inputs