<?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 URGENT code requirement 2 in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/urgent-code-requirement-2/m-p/3731703#M898153</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;Urgently needed code for the below requirement&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Compare records in i_net1 and i_net2 for schedule start and finish dates (SSAVD and SSEDD): For i_net1-aufnr = i_net2-aufnr and i_net1-vornr = i_net2-vornr, if (i_net1-ssavd NE i_net2-ssavd OR i_net1-ssedd NE i_net2-ssedd), write i_net1-aufnr, i_net1-vornr, i_net1-kdauf, i_net1-kdpos, i_net1-ltxa1, i_net1-projn, i_net1-matnr_lo, i_net1-sernr_lo, i_net1-arbpl, i_net1-erdat, i_net1-ssavd, i_net1-ssedd, i_net2-erdat, i_net2-ssavd, i_net2-ssedd to internal table, i_net3 (write i_net1-erdat as i_net3-erdat1, i_net2-erdat as i_net3-erdat2, i_net1-ssavd as i_net3-ssavd1, i_net2-ssavd as i_net3-ssavd2, i_net1-ssedd as i_net3-ssedd1 and i_net2-ssedd as i_net3-ssedd2). If there are no reecords in i_net3, display message &amp;#147;No data found for selection criteria&amp;#148; if P_R1 selected and send a flat file with message &amp;#147;No data found for selection criteria&amp;#148; if P_R2 is selected. &lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Rewarded with points&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: chidambar dixit on May 4, 2008 12:48 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 04 May 2008 10:47:41 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-05-04T10:47:41Z</dc:date>
    <item>
      <title>URGENT code requirement 2</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/urgent-code-requirement-2/m-p/3731703#M898153</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;Urgently needed code for the below requirement&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Compare records in i_net1 and i_net2 for schedule start and finish dates (SSAVD and SSEDD): For i_net1-aufnr = i_net2-aufnr and i_net1-vornr = i_net2-vornr, if (i_net1-ssavd NE i_net2-ssavd OR i_net1-ssedd NE i_net2-ssedd), write i_net1-aufnr, i_net1-vornr, i_net1-kdauf, i_net1-kdpos, i_net1-ltxa1, i_net1-projn, i_net1-matnr_lo, i_net1-sernr_lo, i_net1-arbpl, i_net1-erdat, i_net1-ssavd, i_net1-ssedd, i_net2-erdat, i_net2-ssavd, i_net2-ssedd to internal table, i_net3 (write i_net1-erdat as i_net3-erdat1, i_net2-erdat as i_net3-erdat2, i_net1-ssavd as i_net3-ssavd1, i_net2-ssavd as i_net3-ssavd2, i_net1-ssedd as i_net3-ssedd1 and i_net2-ssedd as i_net3-ssedd2). If there are no reecords in i_net3, display message &amp;#147;No data found for selection criteria&amp;#148; if P_R1 selected and send a flat file with message &amp;#147;No data found for selection criteria&amp;#148; if P_R2 is selected. &lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Rewarded with points&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: chidambar dixit on May 4, 2008 12:48 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 04 May 2008 10:47:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/urgent-code-requirement-2/m-p/3731703#M898153</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-04T10:47:41Z</dc:date>
    </item>
    <item>
      <title>Re: URGENT code requirement 2</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/urgent-code-requirement-2/m-p/3731704#M898154</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;Declare an internal table inet3 with required fields :&lt;/P&gt;&lt;P&gt;  aufnr, vornr, kdauf, kdpos, ltxa1, projn, matnr_lo, sernr_lo,  &lt;/P&gt;&lt;P&gt;  arbpl, erdat1, ssavd1, ssedd1, erdat2, ssavd2, ssedd2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;parameters: dwn_file LIKE rlgrap-filename DEFAULT '/abap/'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Try the following code.&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="--------------------------------------------------" /&gt;&lt;P&gt;SORT i_net1 BY aufnr vornr.&lt;/P&gt;&lt;P&gt;SORT i_net2 BY aufnr vornr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT i_net1.&lt;/P&gt;&lt;P&gt;  READ TABLE i_net2 WITH KEY aufnr = i_net1-aufnr and&lt;/P&gt;&lt;P&gt;                                                  vornr = i_net1-vornr&lt;/P&gt;&lt;P&gt;                                                  BINARY SEARCH.&lt;/P&gt;&lt;P&gt;  IF sy-subrc = 0.&lt;/P&gt;&lt;P&gt;    IF ( ( i_net1-ssavd NE i_net2-ssavd ) OR&lt;/P&gt;&lt;P&gt;         ( i_net1-ssedd NE i_net2-ssedd) ).&lt;/P&gt;&lt;P&gt;      MOVE-CORRESPONDING inet1 TO i_net3.&lt;/P&gt;&lt;P&gt;      MOVE: i_net1-erdat TO i_net3-erdat1,&lt;/P&gt;&lt;P&gt;                  i_net2-erdat TO i_net3-erdat2,&lt;/P&gt;&lt;P&gt;                  i_net1-ssavd TO i_net3-ssavd1,&lt;/P&gt;&lt;P&gt;                  i_net2-ssavd TO i_net3-ssavd2,&lt;/P&gt;&lt;P&gt;                  i_net1-ssedd TO i_net3-ssedd1,&lt;/P&gt;&lt;P&gt;                  i_net2-ssedd as i_net3-ssedd2.&lt;/P&gt;&lt;P&gt;    ENDIF.&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;*for your requirement I suppose that P_R1 and P_R2 are radiobuttons.&lt;/P&gt;&lt;P&gt;*declare a message 'NNN' with 'No data found for selection criteria' in your message class in SE91&lt;/P&gt;&lt;P&gt;*and give that number in the following code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF i_net3 IS INITIAL[].&lt;/P&gt;&lt;P&gt;   If P_R1 = 'X'.&lt;/P&gt;&lt;P&gt;      MESSAGE INNN. &lt;/P&gt;&lt;P&gt;   ENDIF.&lt;/P&gt;&lt;P&gt;  IF P_R2 = 'X'.&lt;/P&gt;&lt;P&gt;    OPEN DATASET dwn_file FOR OUTPUT IN TEXT MODE.&lt;/P&gt;&lt;P&gt;     TRANSFER 'No data found for selection criteria'  TO dwn_file.&lt;/P&gt;&lt;P&gt;     CLOSE DATASET dwn_file.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For condition when P_R2 is selected, the file is downloaded to application server.&lt;/P&gt;&lt;P&gt;Reward  points if useful.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Satya,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 04 May 2008 11:42:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/urgent-code-requirement-2/m-p/3731704#M898154</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-04T11:42:56Z</dc:date>
    </item>
  </channel>
</rss>

