<?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 Help.. in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/3117136#M740221</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Masters!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have two fields in one internal table..namely field1 and field2..each field has a corresponding value..my problem is I want to get their last value..example:&lt;/P&gt;&lt;P&gt;field1  &lt;/P&gt;&lt;P&gt;1&lt;/P&gt;&lt;P&gt;2&lt;/P&gt;&lt;P&gt;3&lt;/P&gt;&lt;P&gt;field2&lt;/P&gt;&lt;P&gt;1         &lt;/P&gt;&lt;P&gt;2&lt;/P&gt;&lt;P&gt;3&lt;/P&gt;&lt;P&gt;4&lt;/P&gt;&lt;P&gt;since field1 has its last value of 3 and field2 has its value of 4..&lt;/P&gt;&lt;P&gt;I need to get those value..&lt;/P&gt;&lt;P&gt;field1 = 3 and field2 = 4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could you help me to compose my logic and my coding..please help me..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 03 Dec 2007 00:57:29 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-12-03T00:57:29Z</dc:date>
    <item>
      <title>Help..</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/3117136#M740221</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Masters!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have two fields in one internal table..namely field1 and field2..each field has a corresponding value..my problem is I want to get their last value..example:&lt;/P&gt;&lt;P&gt;field1  &lt;/P&gt;&lt;P&gt;1&lt;/P&gt;&lt;P&gt;2&lt;/P&gt;&lt;P&gt;3&lt;/P&gt;&lt;P&gt;field2&lt;/P&gt;&lt;P&gt;1         &lt;/P&gt;&lt;P&gt;2&lt;/P&gt;&lt;P&gt;3&lt;/P&gt;&lt;P&gt;4&lt;/P&gt;&lt;P&gt;since field1 has its last value of 3 and field2 has its value of 4..&lt;/P&gt;&lt;P&gt;I need to get those value..&lt;/P&gt;&lt;P&gt;field1 = 3 and field2 = 4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could you help me to compose my logic and my coding..please help me..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 00:57:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/3117136#M740221</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-03T00:57:29Z</dc:date>
    </item>
    <item>
      <title>Re: Help..</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/3117137#M740222</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There are many ways to do this, but you can try:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
SORT itab BY field1 DESCENDING.
READ TABLE itab index 1.                      "Last value of field1.

SORT itab BY field2 DESCENDING.
READ TABLE itab index 1.                     "Last value of field2.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Rob Burbank&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 01:36:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/3117137#M740222</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-03T01:36:04Z</dc:date>
    </item>
    <item>
      <title>Re: Help..</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/3117138#M740223</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Salma,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   I want o ask one thing in this .&lt;/P&gt;&lt;P&gt;Suppose &lt;/P&gt;&lt;P&gt;field1 &lt;/P&gt;&lt;P&gt;1&lt;/P&gt;&lt;P&gt;3&lt;/P&gt;&lt;P&gt;2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;field1 &lt;/P&gt;&lt;P&gt;2&lt;/P&gt;&lt;P&gt;3&lt;/P&gt;&lt;P&gt;1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If this is the case then you want 2 in field1 and 1 in field 2. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If it is not the case , Then you just sort these two fields in decending order and get the topmost value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;here is the code:-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sort itab1 by field1 descending.&lt;/P&gt;&lt;P&gt;move: itab1-field1 to wa_field1.&lt;/P&gt;&lt;P&gt;sort itab2 by field2 descending.&lt;/P&gt;&lt;P&gt;move: itab2-field2 to wa_field2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now use these variables for your further logic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Mamta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 03:58:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/3117138#M740223</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-03T03:58:52Z</dc:date>
    </item>
    <item>
      <title>Re: Help..</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/3117139#M740224</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Salma..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;suppose you want the perticular value you can go for the below code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SORT itab BY field1 DESCENDING.&lt;/P&gt;&lt;P&gt;READ TABLE itab where field1 eq 3 .                       &lt;/P&gt;&lt;P&gt;SORT itab BY field2 DESCENDING.&lt;/P&gt;&lt;P&gt;READ TABLE itab where field2 eq 4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;otherwise if want only the last values,then as others told,you can code in your program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward if helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 05:10:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/3117139#M740224</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-03T05:10:49Z</dc:date>
    </item>
  </channel>
</rss>

