<?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: Date Conversion in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-conversion/m-p/4618196#M1088061</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No need to convert the first date, leave it as it is;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do the following with the second date;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;data : lv_date2(10) type c value '10/21/2008', "Date 2
         lv_date1 type d value ' 20081020', " Date 1
         lv_date2new type d. " date 2 in default format

lv_date2new(4) = lv_date2+6(4). " copy Year
lv_date2new+4(2) = lv_date2(2). " copy Month
lv_date2new+6(2) = lv_date2+3(2). " Copy Day&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now Check/compare the dates.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;For example IF lv_date2new EQ lv_Date1 --- &amp;gt; will return False.&lt;/STRONG&gt;&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;Karthik D&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 21 Oct 2008 07:50:24 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-10-21T07:50:24Z</dc:date>
    <item>
      <title>Date Conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-conversion/m-p/4618194#M1088059</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;I am comapring two date fields. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First is inverted date which i am converting to normal date through FM "CONVERSION_EXIT_INVDT_OUTPUT" and the output is in the format dd/mm/yyyy.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Second date is in format mm/dd/yyyy.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How can I compare these two dates ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can't convert these second date fromat, So please advice me on how to convert first date format dd/mm/yyyy to mm/dd/yyyy ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sri Arun Prian.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Oct 2008 07:25:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-conversion/m-p/4618194#M1088059</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-21T07:25:10Z</dc:date>
    </item>
    <item>
      <title>Re: Date Conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-conversion/m-p/4618195#M1088060</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;you have to define two variables with type d (format will be YYYYMMDD) and transform both dates into these variables and make comparison afterwards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Oct 2008 07:27:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-conversion/m-p/4618195#M1088060</guid>
      <dc:creator>JozsefSzikszai</dc:creator>
      <dc:date>2008-10-21T07:27:22Z</dc:date>
    </item>
    <item>
      <title>Re: Date Conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-conversion/m-p/4618196#M1088061</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No need to convert the first date, leave it as it is;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do the following with the second date;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;data : lv_date2(10) type c value '10/21/2008', "Date 2
         lv_date1 type d value ' 20081020', " Date 1
         lv_date2new type d. " date 2 in default format

lv_date2new(4) = lv_date2+6(4). " copy Year
lv_date2new+4(2) = lv_date2(2). " copy Month
lv_date2new+6(2) = lv_date2+3(2). " Copy Day&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now Check/compare the dates.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;For example IF lv_date2new EQ lv_Date1 --- &amp;gt; will return False.&lt;/STRONG&gt;&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;Karthik D&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Oct 2008 07:50:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-conversion/m-p/4618196#M1088061</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-21T07:50:24Z</dc:date>
    </item>
    <item>
      <title>Re: Date Conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-conversion/m-p/4618197#M1088062</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;use FM &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;FORMAT_DATE_4_OUTPUT&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt; Ex:Import: datin : 20.10.2008 
     and format : MM/DD/YYYY.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;output : 10/20/2008&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sathish Reddy.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Oct 2008 08:53:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-conversion/m-p/4618197#M1088062</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-21T08:53:13Z</dc:date>
    </item>
  </channel>
</rss>

