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

Can we use 'SORT' Command in SAPSCRIPT.

Former Member
0 Likes
1,262

can we sort the internal table in the sapscript .the table is containing the text elements used in the script and is passed by the driver program to the script.

8 REPLIES 8
Read only

Former Member
0 Likes
1,052

Hi Faisal ,

We cannot sort an internal table in sapscript .

Regards

Aru

Read only

Former Member
0 Likes
1,052

i think this is impossible.

Read only

Clemenss
Active Contributor
0 Likes
1,052

???

How is the table [containing text elements] passed by the driver program to the script?

What is the table structure like?

How can a script (FORM) make use of text elements passed as internal table?

If you found that in standard SAP, please give names.

Regards,

Clemens

Read only

Former Member
0 Likes
1,052

Hi,

The internal table always can be sorted...

Let me have the structure and necessity for sorting the internal table which will be passed to sapscript.

Regards,

Satya.

Read only

0 Likes
1,052

"The internal table always can be sorted" and "it never rains in southern California". Yes, indeed.

SORT is ABAP, not SAPSCRIPT. You always need an interface ABAP<==>SAPSCRIPT.

Regards,

Clemens

Read only

0 Likes
1,052

Hi Satya,

The script is for excise register RG1 .the program is : j_2irrg1 and the form is :j_2i_rg1

I want to sort the T_RG1 table without modifying the driver program.

Thanks ,

Read only

Former Member
0 Likes
1,052

Hello

you can not use a SORT command in your SAP-script. However you have always a print program for your sapscript. In that program normally is a loop over a internal table in which is the information which is printed. If you sort this table before the loop your problem is solved.

It is an easy change if you were to change it.

Regards.

Read only

Former Member
0 Likes
1,052

Hi Faisal,

It is not possible to sort the data in sapscript. You need to sort the data before passing the value into sapscript.