Quantcast
Viewing all articles
Browse latest Browse all 8451

Re: How to sort internal table by field length?

Hi Rama,

 

as you can see, we will determine the length of your data in the first Loop.

e.g. STRLEN( FIELD1 ) will deliver "4" for  the value "B-BC".
Then we sort the related value/length-pairs by the length.

In the second Loop your data-table will be re-build in order of length, but only with your value.

 

with the requirement stated above, you just copy this code and change some variable-names.

it will work..

 

If your field1-component is not type string you can try to use SHIFT RIGHT on the component and then sort the internal table...

 

Regards,

 

Jan Martin


Viewing all articles
Browse latest Browse all 8451

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>