<?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 Problem in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874478#M674555</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;For mandatory field you can specify "OBLIGATORY".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To assign default values to a selection criterion, you use the following syntax:&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS &amp;lt;seltab&amp;gt; FOR &amp;lt;f&amp;gt; DEFAULT &amp;lt;g&amp;gt; [TO &amp;lt;h&amp;gt;] ....&lt;/P&gt;&lt;P&gt;Default values &amp;lt;g&amp;gt; and &amp;lt;h&amp;gt; can be literals or field names. You can only use fields that contain a value when the program is started. These fields include several predefined data objects.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For each SELECT-OPTIONS statement, you can specify only one DEFAULT addition. This means that you can fill only the first row of selection table &amp;lt;seltab&amp;gt; with default values. To fill more rows with default values, the selection table must be processed before the selection screen is called, for example, during the AT SELECTION-SCREEN -OUTPUT event.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You use the DEFAULT addition as follows to address the individual components of the first row:&lt;/P&gt;&lt;P&gt;  To fill only the LOW field (single field comparison), use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt;.&lt;/P&gt;&lt;P&gt;  To fill the LOW and HIGH fields (range selection), use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt; TO &amp;lt;h&amp;gt;.&lt;/P&gt;&lt;P&gt;  To fill the OPTION field, use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt; [to &amp;lt;h&amp;gt;] OPTION &amp;lt;op&amp;gt;.&lt;/P&gt;&lt;P&gt;For single field comparisons, &amp;lt;op&amp;gt; can be EQ, NE, GE, GT, LE, LT, CP, or NP. The default value is EQ. For range selections, &amp;lt;op&amp;gt; can be BT or NB. The default value is BT.&lt;/P&gt;&lt;P&gt;  To fill the SIGN field, use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt; [to &amp;lt;h&amp;gt;] [OPTION &amp;lt;op&amp;gt;] SIGN &amp;lt;s&amp;gt;.&lt;/P&gt;&lt;P&gt;The value of &amp;lt;s&amp;gt; can be I or E. The default value is I.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The input fields of the selection criterion are filled with the default values. The user can accept or change these values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ex&lt;/P&gt;&lt;P&gt;REPORT DEMO.&lt;/P&gt;&lt;P&gt;DATA WA_SPFLI TYPE SPFLI.&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS AIRLINE FOR WA_SPFLI-CARRID&lt;/P&gt;&lt;P&gt;DEFAULT 'AA'&lt;/P&gt;&lt;P&gt;TO 'LH'&lt;/P&gt;&lt;P&gt;OPTION NB&lt;/P&gt;&lt;P&gt;SIGN I obligatory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Bhaskar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 21 Sep 2007 06:18:26 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-09-21T06:18:26Z</dc:date>
    <item>
      <title>Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874470#M674547</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;Is it possible to set the default value in select options &amp;amp; at the same time make that field mandatory??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pls suggest me asap.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:03:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874470#M674547</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-21T06:03:36Z</dc:date>
    </item>
    <item>
      <title>Re: Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874471#M674548</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes this is possible. You can use F1 help to get the exact syntax.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REWARDS IF HELPFUL!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:05:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874471#M674548</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-21T06:05:10Z</dc:date>
    </item>
    <item>
      <title>Re: Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874472#M674549</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;Put "obligatory" at the end.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select-options : s_lifnr for lfa1-lifnr obligatory. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Reward If Helpful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:05:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874472#M674549</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-21T06:05:44Z</dc:date>
    </item>
    <item>
      <title>Re: Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874473#M674550</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;Yes  , It is possible to have default value  and mandtory too...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Refer below link&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; parameters: sdate like sy-datum default sy-datum obligatory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this info will help you.Rewards points if useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With Regards, &lt;/P&gt;&lt;P&gt;K K V&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:06:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874473#M674550</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-21T06:06:41Z</dc:date>
    </item>
    <item>
      <title>Re: Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874474#M674551</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes you can do so &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can do so &lt;/P&gt;&lt;P&gt;pass the default value from the initialization event&lt;/P&gt;&lt;P&gt;and make the mandatory when declaring the select-options&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;siva.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:10:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874474#M674551</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-21T06:10:01Z</dc:date>
    </item>
    <item>
      <title>Re: Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874475#M674552</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;Yes it is possible,&lt;/P&gt;&lt;P&gt;syntax is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select-options: s_vendor for lfa1-lifnr default '20001355' obligatory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you want to fill more than one value then ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; REFRESH s_mwskz.&lt;/P&gt;&lt;P&gt;  CLEAR s_mwskz.&lt;/P&gt;&lt;P&gt;  SELECT   mwskz INTO s_mwskz-low&lt;/P&gt;&lt;P&gt;         FROM  t007a CLIENT SPECIFIED&lt;/P&gt;&lt;P&gt;         WHERE  mandt  = sy-mandt&lt;/P&gt;&lt;P&gt;         AND    kalsm  = 'TAXINN'&lt;/P&gt;&lt;P&gt;         AND    mwart  = 'V'.&lt;/P&gt;&lt;P&gt;    s_mwskz-sign = 'I'.&lt;/P&gt;&lt;P&gt;    s_mwskz-option = 'EQ'.&lt;/P&gt;&lt;P&gt;    APPEND s_mwskz.&lt;/P&gt;&lt;P&gt;  ENDSELECT.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:11:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874475#M674552</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-21T06:11:07Z</dc:date>
    </item>
    <item>
      <title>Re: Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874476#M674553</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Neha,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is possible to set the default value in select options &amp;amp; at the same time make that field mandatory. Please have a look at the given example.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME.&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS :  s_mtart  FOR mara-mtart obligatory.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN END OF BLOCK b2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;INITIALIZATION.&lt;/P&gt;&lt;P&gt; s_mtart-sign    = 'E'.&lt;/P&gt;&lt;P&gt; s_mtart-option  = 'EQ'.&lt;/P&gt;&lt;P&gt; s_mtart-low     = 'RELI'.&lt;/P&gt;&lt;P&gt; APPEND s_mtart.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; s_mtart-sign    = 'E'.&lt;/P&gt;&lt;P&gt; s_mtart-option  = 'EQ'.&lt;/P&gt;&lt;P&gt; s_mtart-low     = 'DOC'.&lt;/P&gt;&lt;P&gt; APPEND s_mtart.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this will resolve ur problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:11:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874476#M674553</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-21T06:11:32Z</dc:date>
    </item>
    <item>
      <title>Re: Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874477#M674554</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi neha,&lt;/P&gt;&lt;P&gt;use code like..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tables : MKPF&lt;/P&gt;&lt;P&gt;select-options : budat for mkpf-Budat default sy-datum to sy-datum obligatory.&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;Gagan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:12:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874477#M674554</guid>
      <dc:creator>former_member194152</dc:creator>
      <dc:date>2007-09-21T06:12:47Z</dc:date>
    </item>
    <item>
      <title>Re: Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874478#M674555</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;For mandatory field you can specify "OBLIGATORY".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To assign default values to a selection criterion, you use the following syntax:&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS &amp;lt;seltab&amp;gt; FOR &amp;lt;f&amp;gt; DEFAULT &amp;lt;g&amp;gt; [TO &amp;lt;h&amp;gt;] ....&lt;/P&gt;&lt;P&gt;Default values &amp;lt;g&amp;gt; and &amp;lt;h&amp;gt; can be literals or field names. You can only use fields that contain a value when the program is started. These fields include several predefined data objects.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For each SELECT-OPTIONS statement, you can specify only one DEFAULT addition. This means that you can fill only the first row of selection table &amp;lt;seltab&amp;gt; with default values. To fill more rows with default values, the selection table must be processed before the selection screen is called, for example, during the AT SELECTION-SCREEN -OUTPUT event.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You use the DEFAULT addition as follows to address the individual components of the first row:&lt;/P&gt;&lt;P&gt;  To fill only the LOW field (single field comparison), use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt;.&lt;/P&gt;&lt;P&gt;  To fill the LOW and HIGH fields (range selection), use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt; TO &amp;lt;h&amp;gt;.&lt;/P&gt;&lt;P&gt;  To fill the OPTION field, use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt; [to &amp;lt;h&amp;gt;] OPTION &amp;lt;op&amp;gt;.&lt;/P&gt;&lt;P&gt;For single field comparisons, &amp;lt;op&amp;gt; can be EQ, NE, GE, GT, LE, LT, CP, or NP. The default value is EQ. For range selections, &amp;lt;op&amp;gt; can be BT or NB. The default value is BT.&lt;/P&gt;&lt;P&gt;  To fill the SIGN field, use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt; [to &amp;lt;h&amp;gt;] [OPTION &amp;lt;op&amp;gt;] SIGN &amp;lt;s&amp;gt;.&lt;/P&gt;&lt;P&gt;The value of &amp;lt;s&amp;gt; can be I or E. The default value is I.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The input fields of the selection criterion are filled with the default values. The user can accept or change these values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ex&lt;/P&gt;&lt;P&gt;REPORT DEMO.&lt;/P&gt;&lt;P&gt;DATA WA_SPFLI TYPE SPFLI.&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS AIRLINE FOR WA_SPFLI-CARRID&lt;/P&gt;&lt;P&gt;DEFAULT 'AA'&lt;/P&gt;&lt;P&gt;TO 'LH'&lt;/P&gt;&lt;P&gt;OPTION NB&lt;/P&gt;&lt;P&gt;SIGN I obligatory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Bhaskar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:18:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874478#M674555</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-21T06:18:26Z</dc:date>
    </item>
    <item>
      <title>Re: Date Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874479#M674556</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Neha,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use the below code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS: s_date FOR sy-datum DEFAULT '20070901' TO '20070921' obligatory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*To make S_DATE-HIGH Also mandatory. &lt;/P&gt;&lt;P&gt;AT SELECTION-SCREEN OUTPUT.&lt;/P&gt;&lt;P&gt;  LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;    IF screen-name = 'S_DATE-HIGH'.&lt;/P&gt;&lt;P&gt;      screen-required = '1'.&lt;/P&gt;&lt;P&gt;      MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;  ENDLOOP.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Sep 2007 06:32:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-problem/m-p/2874479#M674556</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-09-21T06:32:54Z</dc:date>
    </item>
  </channel>
</rss>

