<?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: Problem with date range in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832663#M354702</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Give your input for P_DATE as 31.03.2006&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 22 Jan 2007 11:45:38 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-01-22T11:45:38Z</dc:date>
    <item>
      <title>Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832656#M354695</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;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to write a select querry with the date limit example: want to select data till particular date, How can I write it. Can any one tell me how to tell me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanx in advance&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Line&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 11:36:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832656#M354695</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T11:36:36Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832657#M354696</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;parameters : p_date like sy-datum

select field1 field2 into table itab from ztable where date LE p_date.&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 11:39:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832657#M354696</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T11:39:52Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832658#M354697</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;If this Date is a Select-option field then&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Select field1 field 2 field 3 into table Itab from XXX &lt;/P&gt;&lt;P&gt;                         where Date&amp;lt;b&amp;gt; in&amp;lt;/b&amp;gt; S_DATE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the date is not a Select-option, then &lt;/P&gt;&lt;P&gt;Select field1 field 2 field 3 into table Itab from XXX &lt;/P&gt;&lt;P&gt;                         where Date between DATE1 and DATE2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt; Sudheer&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 11:41:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832658#M354697</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T11:41:16Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832659#M354698</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;You an write using relational operators.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;select *
    into lt_mkpf
   from mkpf
 where budat LE p_date.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Bhupal Reddy&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 11:41:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832659#M354698</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T11:41:37Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832660#M354699</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanx for your reply,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to collect the data in the internal table till 31.03.2006 how can I write the select querry.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanx in advance,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Line&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 11:41:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832660#M354699</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T11:41:43Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832661#M354700</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;You can add that condition in where statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For the standard tables date format is like YYYYMMDD.&lt;/P&gt;&lt;P&gt;so you can give like WHERE endda LE 20060331 . This will fetch upto required date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Special cases check the date format in table and give it in where condition using less then (LE) or greater than(GE).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;By &lt;/P&gt;&lt;P&gt;Yuvaram&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 11:43:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832661#M354700</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T11:43:05Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832662#M354701</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;U can create two parameter: one for date from and one for date to.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;PARAMETERS: P_FROM TYPE SY-DATUM,
                         P_TO      TYPE SY-DATUM.

AT SELECTION-SCREEN.

    IF P_TO &amp;lt; P_FROM.
       MESSAGE E208(00) WITH 'Dates are wrong'.
    ENDIF.

START-OF-SELECTION.

    SELECT * FROM &amp;lt;TABLE&amp;gt; WHERE DATE =&amp;gt; P_FROM AND
                                                           DATE &amp;lt;= P_TO&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 11:44:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832662#M354701</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T11:44:07Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832663#M354702</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Give your input for P_DATE as 31.03.2006&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 11:45:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832663#M354702</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T11:45:38Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832664#M354703</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;use WHERE extension of select statemet.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tables: vbak.&lt;/P&gt;&lt;P&gt;parameters : s_date like sy-datum.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: begin of itab occurs 0,&lt;/P&gt;&lt;P&gt;      vbeln like vbak-vbeln,&lt;/P&gt;&lt;P&gt;      erdat like vbak-erdat,&lt;/P&gt;&lt;P&gt;      end of itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select vbeln erdat from vbak into table itab up to 5 rows &amp;lt;b&amp;gt;WHERE&amp;lt;/b&amp;gt; erdat &amp;lt;b&amp;gt;LT&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt; s_date.&lt;/P&gt;&lt;P&gt; if sy-subrc eq 0.&lt;/P&gt;&lt;P&gt; loop at itab.&lt;/P&gt;&lt;P&gt;  write:/ itab-vbeln, itab-erdat.&lt;/P&gt;&lt;P&gt; endloop.&lt;/P&gt;&lt;P&gt; endif.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 11:49:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832664#M354703</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T11:49:56Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with date range</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832665#M354704</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;How Can I assign date to the particular variable.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Line&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jan 2007 12:31:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-date-range/m-p/1832665#M354704</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-22T12:31:37Z</dc:date>
    </item>
  </channel>
</rss>

