<?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: Code modification to read fixed vendor (Urgent) in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173895#M755229</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; Check the below logic:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;if sy-datum &amp;gt;= 1.1.2000 and sy-datum  &amp;lt;= 31.12.2003.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;   &lt;STRONG&gt;vendor = vendor1.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;elseif sy-datum &amp;gt;= 1.1.2004 and sy-datum  &amp;lt;= 31.12.2007.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;   &lt;STRONG&gt;vendor = vendor2.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;elseif sy-datum &amp;gt;= 1.1.2008 and sy-datum  &amp;lt;= 31.12.2010.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;   &lt;STRONG&gt;vendor = vendor3.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;endif.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR: Y_LIFNR, Y_FLIFN, WL_MATNR.&lt;/P&gt;&lt;P&gt;SELECT SINGLE LIFNR FLIFN MATNR FROM EORD INTO (Y_LIFNR, Y_FLIFN,&lt;/P&gt;&lt;P&gt;WL_MATNR)&lt;/P&gt;&lt;P&gt;WHERE MATNR EQ MARC-MATNR&lt;/P&gt;&lt;P&gt;AND WERKS EQ MARC-WERKS&lt;/P&gt;&lt;P&gt;AND FLIFN NE ' '.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;and lifnr = vendor&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;AND VDATU &amp;gt;= SY-DATUM&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;AND BDATU &amp;lt;= sy-datum&lt;/STRONG&gt; .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 21 Dec 2007 07:48:08 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-12-21T07:48:08Z</dc:date>
    <item>
      <title>Code modification to read fixed vendor (Urgent)</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173892#M755226</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The below code is basically selecting the fixed vendor as per EORD table for a given material - plant combination. But the issue is for this combination, there can be different fixed vendors but during different times&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;eg:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mtl  - A, Plant - 1000&lt;/P&gt;&lt;P&gt;Fixed vendor: Vendor1, From 1.1.2000 To 31.12.2003&lt;/P&gt;&lt;P&gt;Fixed vendor: Vendor2, From 1.1.2004 To 31.12.2007&lt;/P&gt;&lt;P&gt;Fixed vendor: Vendor3, From 1.1.2008 To 31.12.2010&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So i want to add one more condition, which reads the system date &amp;amp; if the system date lies in-between 1.1.2000 to 31.12.2003, it selects vendor 1 or if the system date lies in between 1.1.2004 to 31.12.2007, then select vendor 2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So how can i add this condition? The valid from field is EORD-VDATU &amp;amp; the valid to field is EORD-BDATU&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Code:&lt;/P&gt;&lt;P&gt;CLEAR: Y_LIFNR, Y_FLIFN, WL_MATNR.&lt;/P&gt;&lt;P&gt;SELECT SINGLE LIFNR FLIFN MATNR FROM EORD INTO (Y_LIFNR, Y_FLIFN,&lt;/P&gt;&lt;P&gt;WL_MATNR)&lt;/P&gt;&lt;P&gt;   WHERE MATNR EQ MARC-MATNR&lt;/P&gt;&lt;P&gt;     AND WERKS EQ MARC-WERKS&lt;/P&gt;&lt;P&gt;     AND FLIFN NE ' '.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope my question is clear, await inputs&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Vivek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Dec 2007 07:35:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173892#M755226</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-21T07:35:48Z</dc:date>
    </item>
    <item>
      <title>Re: Code modification to read fixed vendor (Urgent)</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173893#M755227</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Vivek,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WL_MATNR)&lt;/P&gt;&lt;P&gt;WHERE MATNR EQ MARC-MATNR&lt;/P&gt;&lt;P&gt;AND WERKS EQ MARC-WERKS&lt;/P&gt;&lt;P&gt;AND FLIFN NE ' '&lt;/P&gt;&lt;P&gt;AND VDATU LE SYST-DATUM&lt;/P&gt;&lt;P&gt;AND BDATU GE SYST-DATUM.&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;&lt;/P&gt;&lt;P&gt;John.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Dec 2007 07:40:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173893#M755227</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-21T07:40:00Z</dc:date>
    </item>
    <item>
      <title>Re: Code modification to read fixed vendor (Urgent)</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173894#M755228</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi Vivek looks like it cant be done in one select &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT SINGLE LIFNR FLIFN MATNR VDATU BDATU&lt;/P&gt;&lt;P&gt;FROM EORD INTO (Y_LIFNR, Y_FLIFN,&lt;/P&gt;&lt;P&gt;WL_MATNR , y _VDATU  , y _BDATU)&lt;/P&gt;&lt;P&gt;WHERE MATNR EQ MARC-MATNR&lt;/P&gt;&lt;P&gt;AND WERKS EQ MARC-WERKS&lt;/P&gt;&lt;P&gt;AND FLIFN NE ' '.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-datum ge y _VDATU and sy-datum LE y _BDATU.&lt;/P&gt;&lt;P&gt;select single vendor where dates are eq to ur y_*'s&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;same with other conditions as well.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope this works.. award points if useful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Dec 2007 07:46:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173894#M755228</guid>
      <dc:creator>former_member156446</dc:creator>
      <dc:date>2007-12-21T07:46:01Z</dc:date>
    </item>
    <item>
      <title>Re: Code modification to read fixed vendor (Urgent)</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173895#M755229</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; Check the below logic:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;if sy-datum &amp;gt;= 1.1.2000 and sy-datum  &amp;lt;= 31.12.2003.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;   &lt;STRONG&gt;vendor = vendor1.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;elseif sy-datum &amp;gt;= 1.1.2004 and sy-datum  &amp;lt;= 31.12.2007.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;   &lt;STRONG&gt;vendor = vendor2.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;elseif sy-datum &amp;gt;= 1.1.2008 and sy-datum  &amp;lt;= 31.12.2010.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;   &lt;STRONG&gt;vendor = vendor3.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;endif.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR: Y_LIFNR, Y_FLIFN, WL_MATNR.&lt;/P&gt;&lt;P&gt;SELECT SINGLE LIFNR FLIFN MATNR FROM EORD INTO (Y_LIFNR, Y_FLIFN,&lt;/P&gt;&lt;P&gt;WL_MATNR)&lt;/P&gt;&lt;P&gt;WHERE MATNR EQ MARC-MATNR&lt;/P&gt;&lt;P&gt;AND WERKS EQ MARC-WERKS&lt;/P&gt;&lt;P&gt;AND FLIFN NE ' '.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;and lifnr = vendor&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;AND VDATU &amp;gt;= SY-DATUM&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;AND BDATU &amp;lt;= sy-datum&lt;/STRONG&gt; .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Dec 2007 07:48:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173895#M755229</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-21T07:48:08Z</dc:date>
    </item>
    <item>
      <title>Re: Code modification to read fixed vendor (Urgent)</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173896#M755230</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;data: begin of it_mara occurs 0,&lt;/P&gt;&lt;P&gt;           LIFNR TYPE LIFNR,       &lt;/P&gt;&lt;P&gt;           FLIFN TYPE FLIFN,       &lt;/P&gt;&lt;P&gt;           MATNR TYPE MATNR, &lt;/P&gt;&lt;P&gt;           VDATU TYPE sy-datum,&lt;/P&gt;&lt;P&gt;          bdatu type sy-datum,      &lt;/P&gt;&lt;P&gt;        end of it_mara.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT LIFNR &lt;/P&gt;&lt;P&gt;             FLIFN &lt;/P&gt;&lt;P&gt;             MATNR &lt;/P&gt;&lt;P&gt;             VDATU&lt;/P&gt;&lt;P&gt;             BDATU&lt;/P&gt;&lt;P&gt;             FROM EORD &lt;/P&gt;&lt;P&gt;             into corresponding field of table it_mara&lt;/P&gt;&lt;P&gt;WHERE MATNR EQ MARC-MATNR&lt;/P&gt;&lt;P&gt;AND WERKS EQ MARC-WERKS&lt;/P&gt;&lt;P&gt;AND FLIFN NE ' '.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DELETE it_mara&lt;/P&gt;&lt;P&gt;             where vdatu &amp;lt; sy-datum&lt;/P&gt;&lt;P&gt;              and   bdatu &amp;gt; sy-datum.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Dec 2007 07:49:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173896#M755230</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-21T07:49:26Z</dc:date>
    </item>
    <item>
      <title>Re: Code modification to read fixed vendor (Urgent)</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173897#M755231</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Mr. John,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much for that simple solution. Thanks to the rest for providing different alternatives. Keep the good work going.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vivek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Dec 2007 07:56:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/code-modification-to-read-fixed-vendor-urgent/m-p/3173897#M755231</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-21T07:56:50Z</dc:date>
    </item>
  </channel>
</rss>

