<?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: Sort statement behaviour in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831793#M921404</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi check one thing ..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1 .sort is  used to get the details  at the asending order or in the descending order ..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check this for ascending order..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sort itab by field1 ascending&lt;/P&gt;&lt;P&gt;---means here the field1 values are stored in the table in the ascending order ...like 1 2 3 4 ....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sort itab by field1 desceding &lt;/P&gt;&lt;P&gt;---means here the field1 values are stored in the table in the descending order ...6 5 4 3 2 1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;with this sort you can get the recent record with in the no of records...&lt;/P&gt;&lt;P&gt;read statemet is used for reading one record which met the condtion ..for fast action bynary search is used..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check this for more information..&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/sort.htm" target="test_blank"&gt;http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/sort.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;venkat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 15 May 2008 19:20:58 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-05-15T19:20:58Z</dc:date>
    <item>
      <title>Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831791#M921402</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am working on a performance tuning of an extract that runs for 7 hrs. Well, I got it down to 1 hour but noticing the data differences (Telephone numbers). And when I debugged the old and new, noticed the sort statement behaves differently. Both programs use the same sort statement. &lt;/P&gt;&lt;P&gt;           SORT t_adr2 BY addrnumber date_from.&lt;/P&gt;&lt;P&gt;One sorts in the order&lt;/P&gt;&lt;P&gt;tel1&lt;/P&gt;&lt;P&gt;tel2&lt;/P&gt;&lt;P&gt;tel3&lt;/P&gt;&lt;P&gt;and other sorts &lt;/P&gt;&lt;P&gt;tel3&lt;/P&gt;&lt;P&gt;tel2&lt;/P&gt;&lt;P&gt;tel1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The program reads the first telephone number that it gets after sorting. &lt;/P&gt;&lt;P&gt;                  Read itab index 1.&lt;/P&gt;&lt;P&gt;Because the sort order is different I am getting different values from old and new programs. Any feedback will be appeciated. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;P.S - When I run both the programs for just one customer, I don't run into this issue. Both the programs return me the same  values. But they are different when I run the program wide open. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Anu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2008 19:07:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831791#M921402</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-15T19:07:35Z</dc:date>
    </item>
    <item>
      <title>Re: Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831792#M921403</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Why don't u sort it using ascending or descending.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2008 19:18:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831792#M921403</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-15T19:18:40Z</dc:date>
    </item>
    <item>
      <title>Re: Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831793#M921404</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi check one thing ..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1 .sort is  used to get the details  at the asending order or in the descending order ..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check this for ascending order..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sort itab by field1 ascending&lt;/P&gt;&lt;P&gt;---means here the field1 values are stored in the table in the ascending order ...like 1 2 3 4 ....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sort itab by field1 desceding &lt;/P&gt;&lt;P&gt;---means here the field1 values are stored in the table in the descending order ...6 5 4 3 2 1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;with this sort you can get the recent record with in the no of records...&lt;/P&gt;&lt;P&gt;read statemet is used for reading one record which met the condtion ..for fast action bynary search is used..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check this for more information..&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/sort.htm" target="test_blank"&gt;http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/sort.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;venkat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2008 19:20:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831793#M921404</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-15T19:20:58Z</dc:date>
    </item>
    <item>
      <title>Re: Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831794#M921405</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is the combination "addrnumber date_from" unique when you run it wide open?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2008 19:21:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831794#M921405</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-15T19:21:37Z</dc:date>
    </item>
    <item>
      <title>Re: Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831795#M921406</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I appreciate your quick turn around. But my objective here is to match the data with the old program. The old program do not use any ascending and descending addition. Neither I see the use of it. If you notice the help on SORT statement, you will see some notes on addition 'STABLE'  the exact situation I am running into. But I am dealing with 2 different program so I can't make use of it. &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;I just want to know  why the system sorts the tables differently even though the sort criteria is same and is there anything I can do to make sure they match. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Anu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2008 19:32:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831795#M921406</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-15T19:32:31Z</dc:date>
    </item>
    <item>
      <title>Re: Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831796#M921407</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi under stand one thing...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;suppose i had a field at the third column  of the field ...with this field i am reading the another table...if u dont use the sort command then it will checks the first field and checks the second field...and then third field which is not good for performance....if u use the sort then the table sorts data with the specified field to the first position so it will hit the condition in the first attempt only..so the performance will incrases..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you got the answer award the good answer and close the thread..please..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;venkat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2008 19:45:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831796#M921407</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-15T19:45:57Z</dc:date>
    </item>
    <item>
      <title>Re: Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831797#M921408</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Venkat, &lt;/P&gt;&lt;P&gt;I realise what you are trying to say, but I am not concerned with performance anymore ( I got it down to 1 hr from 7 hrs). Its just the order of the data. I will keep this open to see someone else might help me. But I truely appreciate your response. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Aparna, &lt;/P&gt;&lt;P&gt;The addrnumber and date_from combination is not unique which is the reason I am running into the situation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Anu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2008 20:21:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831797#M921408</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-15T20:21:46Z</dc:date>
    </item>
    <item>
      <title>Re: Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831798#M921409</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Cant you find any other combination of fields which will be unique and then change the sort statement?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2008 20:25:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831798#M921409</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-15T20:25:45Z</dc:date>
    </item>
    <item>
      <title>Re: Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831799#M921410</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;All,&lt;/P&gt;&lt;P&gt;The functional team made a decision to go with the standard telephone number instead of the first telephone number that I get in the internal table for a customer. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That would still not match the old one, but something consistent data going on. I appreciate all your responses. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Anu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 May 2008 20:42:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831799#M921410</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-15T20:42:22Z</dc:date>
    </item>
    <item>
      <title>Re: Sort statement behaviour</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831800#M921411</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Closing this thread .&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Anu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 May 2008 16:01:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sort-statement-behaviour/m-p/3831800#M921411</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-16T16:01:43Z</dc:date>
    </item>
  </channel>
</rss>

