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

Two questions

Former Member
0 Likes
471

Hi,

I have following 2 questions:

1) I want to extract sales document using sold-to and material from VBAK, but don't have primary key document number and also there is no ondex on sold-to. Looking at the enormous data in VBAK,

Can I do

select vbeln from vbak

where vbeln <> ' ' and

sold-to in range.

and then go to VBAP. Will it help performance by putting VBELN BLANK.

2) Can we draw a line in smartform. I see only box creation. Boxes in smartforms don't provide border lines. It has to come thru windows. If the table ends before touching the MAIN window, it has no bottom border line. I want that line. How to acomplish??

Thanks,

Amol..

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
452

Hi,

For your first query go to table VAPMA(Sales Index: Order Items by Ma) and you will get your required data with out any joining and MATNR,KUNNR & VBELN all are primary key fields.

So this will give good performance.

Thanks and regards,

shyla

3 REPLIES 3
Read only

Former Member
0 Likes
452

Any suggestions please.

Thanks

Read only

Former Member
0 Likes
452

Hi AP,

1.U can use the Inner join of two tables VBAP and VBAP based on ur requirment Sold-to party. so that u can retreive ur sales doc belongs to that sold-to party.

select ur fields from tables ( Ex: akunnr avbeln bposnr bmatnr)

INTO CORRESPONDING FIELDS OF TABLE (ur internal table)

FROM VBAK AS A

JOIN VBAP AS B ON AVBELN = BVBELN

WHERE A~KUNNR IN P_KUNNR.

2.IN smartforms the WINDOWS u can see the output options there click the checkboxes DRAW BOXES AND SHADING...

or u can create a window and draw a line in that window where ever u want.

Read only

Former Member
0 Likes
453

Hi,

For your first query go to table VAPMA(Sales Index: Order Items by Ma) and you will get your required data with out any joining and MATNR,KUNNR & VBELN all are primary key fields.

So this will give good performance.

Thanks and regards,

shyla