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

Reg:SAP Query

Former Member
0 Likes
595

Hi ALL,

I have displayed the output in SAP QUery ... i want to change the output position from 1 coloum to another coloum in SAP Query how we can do this can any suugest me

Regards,

Manoja

Moderator message - duplicate post locked.

Edited by: Rob Burbank on May 18, 2009 12:48 PM

Hi ALL,

I have displayed the output in SAP QUery ... i want to change the output position from 1 coloum to another coloum in SAP Query how we can do this can any suugest me

Regards,

Manoja

Moderator message - duplicate post locked.

Edited by: Rob Burbank on May 18, 2009 12:48 PM

4 REPLIES 4
Read only

Former Member
0 Likes
573

Hi.

Suppose your internal table itab has the structure of =>

column1 column2

and you have written the SAP Query to display the output in same format as your internal table structure .

loop at itab.

Write: itab-column1, itab-column2.

endloop

Output:

column1 column2

Now to swap the columns

you have to code in this way

Loop at itab.

write: itab-column2, itab-column1.

endloop.

Output:

Column2 column1

That's it.

Edited by: Anup Verma on May 18, 2009 1:41 PM

Read only

0 Likes
573

I did`t write any of the codings to display automatically it will create the program ..

for this how we can write the coding to display .... there it is not creating the internal table .. so for this how we can write this can u help me ...

Manoja

Read only

Former Member
0 Likes
573

Hi,

Go to SQ01 Transaction than click on the infoset query. There you will find options like

field/field groups selections and output.

You need to click on the check buttons which columns you want to select first.

Hope this will solve your query.

Regards,

Nikhil

Read only

KK07
Contributor
0 Likes
573

Hi,

For changing the order of columns in the output in SAP query in the output just drag and drop the filed which ever needed.first drag the column which you want to change and then drop in the postion where you want to change.There is no need of coding for this.

Cheers,

KK