<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Table Sorting in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239956#M1719631</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Thanks for replying,But in my internal table I have a column which contains list of particular colors just five of them used to define zones as Yellow,White,Green,Red &amp;amp;Black. when I use the ascending order it gives me BRGWY and in descending YWGRB colors format. But I want it as in format Black Red Yellow Green White.So the above syntax does not works.Please suggest me any other solution.&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 04 Jan 2013 06:25:55 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2013-01-04T06:25:55Z</dc:date>
    <item>
      <title>Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239954#M1719629</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I have came with an issue of report in which i have to sort the entries in the table according to some particular entries in a column which as fixed just 5 values in string.Using a simple Sort command I m not able to perform the sort as I required, Please Kindly Help me for the same.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 06:02:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239954#M1719629</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-01-04T06:02:49Z</dc:date>
    </item>
    <item>
      <title>Re: Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239955#M1719630</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you giving the correct order in sorting.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SORT itab BY field1 field2 .. ( use AS TEXT) addition if you want character sorting.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;more details.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_erp60_sp/helpdata/en/fc/eb3800358411d1829f0000e829fbfe/content.htm" title="http://help.sap.com/saphelp_erp60_sp/helpdata/en/fc/eb3800358411d1829f0000e829fbfe/content.htm"&gt;http://help.sap.com/saphelp_erp60_sp/helpdata/en/fc/eb3800358411d1829f0000e829fbfe/content.htm&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 06:13:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239955#M1719630</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-01-04T06:13:45Z</dc:date>
    </item>
    <item>
      <title>Re: Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239956#M1719631</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Thanks for replying,But in my internal table I have a column which contains list of particular colors just five of them used to define zones as Yellow,White,Green,Red &amp;amp;Black. when I use the ascending order it gives me BRGWY and in descending YWGRB colors format. But I want it as in format Black Red Yellow Green White.So the above syntax does not works.Please suggest me any other solution.&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 06:25:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239956#M1719631</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-01-04T06:25:55Z</dc:date>
    </item>
    <item>
      <title>Re: Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239957#M1719632</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;then try &lt;/P&gt;&lt;P&gt;SORT itab BY Black Red Yellow Green White. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Black Red Yellow Green White. will have the columns to be sorted &lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 06:33:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239957#M1719632</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-01-04T06:33:23Z</dc:date>
    </item>
    <item>
      <title>Re: Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239958#M1719633</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi sorry i couldnt get your question are those colors contents of a particular column?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 06:43:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239958#M1719633</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-01-04T06:43:20Z</dc:date>
    </item>
    <item>
      <title>Re: Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239959#M1719634</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV&gt;Hi Ajinkya,&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;Add an extra column in your internal table with serial number against the colors and sort with the serial number.Check the test program below.&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;DIV&gt;&lt;P&gt;TYPES:BEGIN&amp;nbsp; OF s_test,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; col&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TYPE char2,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sorder TYPE n,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; END&amp;nbsp;&amp;nbsp;&amp;nbsp; OF s_test.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;DATA:it_test TYPE STANDARD TABLE OF s_test,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; wa_test TYPE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; s_test.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;wa_test-col&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = 'W'.&lt;BR /&gt;wa_test-sorder&amp;nbsp; = 5.&lt;BR /&gt;APPEND wa_test TO it_test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;wa_test-col = 'Y'.&lt;BR /&gt;wa_test-sorder&amp;nbsp; = 3.&lt;BR /&gt;APPEND wa_test TO it_test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;wa_test-col = 'G'.&lt;BR /&gt;wa_test-sorder&amp;nbsp; = 4.&lt;BR /&gt;APPEND wa_test TO it_test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;wa_test-col = 'B'.&lt;BR /&gt;wa_test-sorder&amp;nbsp; = 1.&lt;BR /&gt;APPEND wa_test TO it_test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;wa_test-col = 'R'.&lt;BR /&gt;wa_test-sorder&amp;nbsp; = 2.&lt;BR /&gt;APPEND wa_test TO it_test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SORT it_test BY col.&lt;/P&gt;&lt;P&gt;LOOP AT it_test INTO wa_test.&lt;BR /&gt;&amp;nbsp; WRITE:/5 wa_test-col.&lt;BR /&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;ULINE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SORT it_test BY sorder.&lt;/P&gt;&lt;P&gt;LOOP AT it_test INTO wa_test.&lt;BR /&gt;&amp;nbsp; WRITE:/5 wa_test-col.&lt;BR /&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;ULINE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With regards,&lt;/P&gt;&lt;/DIV&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 06:51:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239959#M1719634</guid>
      <dc:creator>former_member282968</dc:creator>
      <dc:date>2013-01-04T06:51:36Z</dc:date>
    </item>
    <item>
      <title>Re: Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239960#M1719635</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;Ajinkya&lt;/P&gt;&lt;P&gt;Some text disn posted on my last reply....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;add one more column with integer then modify ur internal table as&lt;/P&gt;&lt;P&gt;Black with 1 &lt;/P&gt;&lt;P&gt;Red with 2&lt;/P&gt;&lt;P&gt;Yellow with 3&lt;/P&gt;&lt;P&gt;Green with 4&lt;/P&gt;&lt;P&gt;White.with 5&amp;nbsp; on the new interger column&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now sort with the new interger colum&lt;/P&gt;&lt;P&gt;SORT itab BY interger.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &lt;/P&gt;&lt;P&gt;Ben&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 06:51:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239960#M1719635</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-01-04T06:51:44Z</dc:date>
    </item>
    <item>
      <title>Re: Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239961#M1719636</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Ajinkya,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What would you do with the internal table once it is sorted in the order you want? Thanks!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kumud&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 06:51:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239961#M1719636</guid>
      <dc:creator>kumud</dc:creator>
      <dc:date>2013-01-04T06:51:57Z</dc:date>
    </item>
    <item>
      <title>Re: Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239962#M1719637</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No ABAP statement will sort those data as you liked it as&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;Character-like components are sorted by default by their binary representation (&lt;A class="grey" title="Glossary Entry"&gt;code page&lt;/A&gt;). Textual sorting of character-like components can be performed using the addition &lt;SPAN class="qtext"&gt;AS TEXT&lt;/SPAN&gt;. &lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;(AFAIK no code page has this order BRYGW, those good old characters from birth of ASCII were always sorted in Latin alphabet order)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So either create another column in the internal table and fill it with 1 for B, 2 for R, etc, and sort with this field (not-displayed) or replace temporary the color codes by values in your required order, sort the table, and replace back with the original color codes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Now you should understand the use of special values in lights_fieldname in ALV grid&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;'1' = red traffic light&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;'2' = yellow traffic light&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;'3' = green traffic light&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;You have to code yourself your own values as you have 2 other values to manage.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Raymond&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 07:08:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239962#M1719637</guid>
      <dc:creator>RaymondGiuseppi</dc:creator>
      <dc:date>2013-01-04T07:08:24Z</dc:date>
    </item>
    <item>
      <title>Re: Table Sorting</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239963#M1719638</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank U all for the reply finally i have got the solution.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 08:03:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-sorting/m-p/9239963#M1719638</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-01-04T08:03:58Z</dc:date>
    </item>
  </channel>
</rss>

