01-05-2006 4:58 AM
Hi everyone,
i need to retrive data from vbak-kunnr,vbak-name1,vbap-posnr,vbak-vbeln.In Va02/va03 screen after entering sales order number,next screen is displayed based on that sales order number i need to retrive data. could some one provide me with the code.
for ex:
select vbeln kunnr name1
from vbak into i_vbak where vbeln = ..... so how should be the where condition
Many thanks
kesi
01-05-2006 5:21 AM
What is your input? Is this a report? The information you gave is very little. Please provide more information.
01-05-2006 5:25 AM
hi,
Are you imitating the va02/va03 transaction.
if so give the vbeln itself in where clause, which you have entered in the first screen. if you are doing some thing with va02/va03 please let me know..
thanks
vijay
01-05-2006 5:42 AM
Hi
after entering sales order number in Va03/Va02 it goes to the next screen. In that screen i have added a button(telephonic button). when a line item is selected along with the button a new screen is displayed, in that it should diplay all the phone numbers assigned to the sales order no. for phone numbers there is a bespoke dbtable in which sales order number is also present.in the same screen i need to display
1. sales order
2. kunnr
3. name1
4.posnr.
so i am little bit confused while using the 'Where' condition.
select vbeln kunnr name1 from vbak
into i_vbak where vbeln = vbeln or vbeln = .......
same vbeln means vbeln = vbeln or somethng different.
cheers
kesi
01-05-2006 5:45 AM
select vbeln kunnr name1 from vbak
into i_vbak where vbeln = scrfeild.
(screen field which is holding vbeln).
try that
01-05-2006 5:46 AM
In VA03/VA02, you should have access to the VBAK or XVBAK structures somewhere. Check in debugging. You can use the VBELN of that structure. But I think most of your fields will be there already, unless these are some custom fields.
Srinivas