<?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: Splitting the date based on the selection screen input in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502881#M1422044</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Ajay,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Find the difference betweem low and high of the selction date (say value = x)&lt;/P&gt;&lt;P&gt;2. Divide x by P_number (say the resut = y)&lt;/P&gt;&lt;P&gt;3. add Y to low of selection data.. till it reaches High value..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please consider point of vinod as well..&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
Are you looking for splitting of date range?  "Please note that Select options can have ranges, exclusions and single values.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Nag&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 12 Jan 2010 08:24:42 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2010-01-12T08:24:42Z</dc:date>
    <item>
      <title>Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502877#M1422040</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;In the Selection screen of my report i had maintained two fields&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;SELECT-OPTIONS  : S_DATE    FOR TPCDATE-FROM_DATE.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;PARAMETERS      : P_NUMBER  TYPE ZMMAREA-NUMBER.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to code such that&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;S_DATE should be splitted into P_NUMBER times &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for example if P_NUMBER is 4 i need  S_DATE should be splitted into 4 equal parts or near by equal parts &lt;/P&gt;&lt;P&gt;                    IF  P_NUMBER is 2 i need  S_DATE should be splitted into 2 equal parts or  near by equal parts &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please suggest me the code of if any Function module exists fot this date splitting &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ajay.D&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:05:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502877#M1422040</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-12T08:05:31Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502878#M1422041</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;your question seems to be not clear to me. Can you eloborate about the requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Are you looking for splitting of date range? Please note that Select options can have ranges, exclusions and single values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Vinod.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:14:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502878#M1422041</guid>
      <dc:creator>vinod_vemuru2</dc:creator>
      <dc:date>2010-01-12T08:14:24Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502879#M1422042</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try this logic:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
SELECT-OPTIONS : S_DATE FOR TPCDATE-FROM_DATE.
PARAMETERS : P_NUMBER TYPE ZMMAREA-NUMBER.

DATA: DAYS TYPE I,
      COUNT TYPE I,
      XXX TYPE I.
DATA: BEGIN OF ITAB OCCURS 0,
      LDATE LIKE SY-DATUM,
      HDATE LIKE SY-DATUM,
      END OF ITAB.

DAYS = S_DATE-HIGH - S_DATE-LOW.
COUNT = TRUNC( DAYS / P_NUMBER ).
XXX = P_NUMBER - 1.
DO XXX TIMES.
  ITAB-LDATE = S_DATE-LOW.
  S_DATE-LOW = S_DATE-LOW + COUNT.
  ITAB-HDATE = S_DATE-LOW.
  APPEND ITAB.
  S_DATE-LOW = S_DATE-LOW + 1.
  CLEAR ITAB.
ENDDO.
ITAB-LDATE = S_DATE-LOW.
ITAB-HDATE = S_DATE-HIGH.
APPEND ITAB.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In table ITAB you will have date intervals.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:23:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502879#M1422042</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-12T08:23:02Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502880#M1422043</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What do you mean by splitting ? Any example .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:24:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502880#M1422043</guid>
      <dc:creator>kesavadas_thekkillath</dc:creator>
      <dc:date>2010-01-12T08:24:16Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502881#M1422044</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Ajay,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Find the difference betweem low and high of the selction date (say value = x)&lt;/P&gt;&lt;P&gt;2. Divide x by P_number (say the resut = y)&lt;/P&gt;&lt;P&gt;3. add Y to low of selection data.. till it reaches High value..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please consider point of vinod as well..&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
Are you looking for splitting of date range?  "Please note that Select options can have ranges, exclusions and single values.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Nag&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:24:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502881#M1422044</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-12T08:24:42Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502882#M1422045</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes u can do as u need i.e, first get the parameter value and then get the difference (in no.of years) between the given date range and divide it by value (given for paratmer) and update the select option accordingly.  But your logic should cover all the cases i.e, if user gives single day for selecti option then how u will divide it based on the parameter value.  So be clear about the requirement first and build logic accordingly.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:24:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502882#M1422045</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-12T08:24:43Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502883#M1422046</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Please be clear with your requirement then only we can suggest some solution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Amit&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:27:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502883#M1422046</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-12T08:27:32Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502884#M1422047</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;though date question are not allowed, this requirement sounds little different. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can take a difference between those days by: S_date-high - S_date-low.&lt;/P&gt;&lt;P&gt;then divide the difference by p_number. now you get the split positions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now in a do enddo you can negate the dates by the split amount you got from the divisions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;like...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;PARAMETERS: num type i.
select-OPTIONS: s_date for sy-datum.

data : gv_split type i, gv_temp type sy-datum.

gv_split = s_date-high - s_date-low.
gv_split = gv_split / num.

gv_temp = s_date-high.
do num times.
  gv_temp = gv_temp - gv_split.
  WRITE / gv_temp.
enddo.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:30:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502884#M1422047</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-12T08:30:50Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502885#M1422048</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Kindly ignore .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Keshav.T on Jan 12, 2010 2:17 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:41:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502885#M1422048</guid>
      <dc:creator>kesavadas_thekkillath</dc:creator>
      <dc:date>2010-01-12T08:41:35Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting the date based on the selection screen input</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502886#M1422049</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check whether &lt;STRONG&gt;RHXPROVIDE_PERIODS&lt;/STRONG&gt; is helpful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Jan 2010 08:50:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/splitting-the-date-based-on-the-selection-screen-input/m-p/6502886#M1422049</guid>
      <dc:creator>kesavadas_thekkillath</dc:creator>
      <dc:date>2010-01-12T08:50:10Z</dc:date>
    </item>
  </channel>
</rss>

