<?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: Select Statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132169#M744115</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sekhar,&lt;/P&gt;&lt;P&gt;Try this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types : begin of struct,&lt;/P&gt;&lt;P&gt;po_num type ztab01-ponumber,&lt;/P&gt;&lt;P&gt;end of struct.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : itab_num1 type standard table of struct with header line,&lt;/P&gt;&lt;P&gt;         itab_num2 type standard table of struct with header line,&lt;/P&gt;&lt;P&gt;         itab_temp type standard table of struct with header line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;********for the first case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select ponumber from ztab01&lt;/P&gt;&lt;P&gt;into table itab_num1&lt;/P&gt;&lt;P&gt;where movement = 351.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*************for the second case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select ponumber from ztab01&lt;/P&gt;&lt;P&gt;into table itab_temp                            "temporary internal table.&lt;/P&gt;&lt;P&gt;where movement = 101.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now to get ponumbers for the second case do this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at itab_num1.&lt;/P&gt;&lt;P&gt;read table itab_temp with key po_num = itab_num1-po_num.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;move itab_temp to itab_num2.&lt;/P&gt;&lt;P&gt;append itab_num2.&lt;/P&gt;&lt;P&gt;clear itab_num2.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;clear itab_temp.&lt;/P&gt;&lt;P&gt;clear itab_num1.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this will solve your problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if it helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 19 Nov 2007 04:58:44 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-11-19T04:58:44Z</dc:date>
    <item>
      <title>Select Statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132164#M744110</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi friends,&lt;/P&gt;&lt;P&gt;i have a small problem ... pls any one give the solution...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PONumber             Movement&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="---------------" /&gt;&lt;P&gt;             -&lt;/P&gt;&lt;HR originaltext="---------------" /&gt;&lt;P&gt;po100                      351&lt;/P&gt;&lt;P&gt;po100                      101&lt;/P&gt;&lt;P&gt;po110                      351&lt;/P&gt;&lt;P&gt;po120                     351&lt;/P&gt;&lt;P&gt;po120                     101&lt;/P&gt;&lt;P&gt;po130                      351&lt;/P&gt;&lt;P&gt;po140                      351&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is a table (say ZTAB01)&lt;/P&gt;&lt;P&gt;now i want to retrieve the PONumbers having only 351 movements  ( ie., po110, po130 and po140 ) ti an itab and ponumbers of both movements 351 &amp;amp; 101 (ie po100,po120)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How to write the select on this scenario.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;advance tanks,&lt;/P&gt;&lt;P&gt;sekhar.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Nov 2007 04:44:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132164#M744110</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-19T04:44:51Z</dc:date>
    </item>
    <item>
      <title>Re: Select Statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132165#M744111</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For only 351 movement&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT PO
INTO TABLE IT_PO_351
FROM ZTAB
WHERE MOVEMENT = '351'.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For both 351 and 101.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT PO
INTO TABLE IT_PO_BOTH
FROM ZTAB
WHERE MOVEMENT IN ('101' , '351').&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Nov 2007 04:48:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132165#M744111</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2007-11-19T04:48:45Z</dc:date>
    </item>
    <item>
      <title>Re: Select Statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132166#M744112</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;loop at itab into wa .&lt;/P&gt;&lt;P&gt;if ( movement = 351 or 101 ) and ( po = 100 or 110 ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Karthikeyan Pandurangan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Nov 2007 04:49:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132166#M744112</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-19T04:49:21Z</dc:date>
    </item>
    <item>
      <title>Re: Select Statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132167#M744113</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ur select query shud be&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Select &amp;lt;PO number&amp;gt; &lt;/P&gt;&lt;P&gt;       from ZTAB01 &lt;/P&gt;&lt;P&gt;       into table itab &lt;/P&gt;&lt;P&gt;       where &amp;lt;movement&amp;gt; = '351'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Select &amp;lt;PO number&amp;gt; &lt;/P&gt;&lt;P&gt;       from ZTAB01 &lt;/P&gt;&lt;P&gt;       into table itab &lt;/P&gt;&lt;P&gt;       where &amp;lt;movement&amp;gt; in (351,101).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Vasudha&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Vasudha L&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Vasudha L&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Nov 2007 04:50:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132167#M744113</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-19T04:50:28Z</dc:date>
    </item>
    <item>
      <title>Re: Select Statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132168#M744114</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;select ponumber from ZTAB01&lt;/P&gt;&lt;P&gt;into corresponding fields of table itab1&lt;/P&gt;&lt;P&gt;where movement eq '351'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select ponumber from ZTAB01&lt;/P&gt;&lt;P&gt;into corresponding fields of table itab1&lt;/P&gt;&lt;P&gt;where movement in (351, 101) .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Nov 2007 04:50:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132168#M744114</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-19T04:50:28Z</dc:date>
    </item>
    <item>
      <title>Re: Select Statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132169#M744115</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sekhar,&lt;/P&gt;&lt;P&gt;Try this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types : begin of struct,&lt;/P&gt;&lt;P&gt;po_num type ztab01-ponumber,&lt;/P&gt;&lt;P&gt;end of struct.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : itab_num1 type standard table of struct with header line,&lt;/P&gt;&lt;P&gt;         itab_num2 type standard table of struct with header line,&lt;/P&gt;&lt;P&gt;         itab_temp type standard table of struct with header line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;********for the first case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select ponumber from ztab01&lt;/P&gt;&lt;P&gt;into table itab_num1&lt;/P&gt;&lt;P&gt;where movement = 351.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*************for the second case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select ponumber from ztab01&lt;/P&gt;&lt;P&gt;into table itab_temp                            "temporary internal table.&lt;/P&gt;&lt;P&gt;where movement = 101.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now to get ponumbers for the second case do this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at itab_num1.&lt;/P&gt;&lt;P&gt;read table itab_temp with key po_num = itab_num1-po_num.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;move itab_temp to itab_num2.&lt;/P&gt;&lt;P&gt;append itab_num2.&lt;/P&gt;&lt;P&gt;clear itab_num2.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;clear itab_temp.&lt;/P&gt;&lt;P&gt;clear itab_num1.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this will solve your problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if it helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Nov 2007 04:58:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-statement/m-p/3132169#M744115</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-19T04:58:44Z</dc:date>
    </item>
  </channel>
</rss>

