<?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: Need help with select statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510627#M1559516</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Started in ABAP  in recently. &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would not use my C or C++ background....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I do that I will never get past the ABAP compiler....I am trying to not compare them&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Vighneswaran CE on Nov 17, 2010 3:30 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 17 Nov 2010 14:29:15 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2010-11-17T14:29:15Z</dc:date>
    <item>
      <title>Need help with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510621#M1559510</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT  SINGLE * into corresponding fields of LS_JOB from DTAB
where
JOB_REPORT = JOBNAME and
JOBCOUNT = JOBCOUNT and
SCHED_START_DATE = today or SCHED_START_DATE = tomorrow .&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the select the requirement is that after the where condition select should be evaluated in the following way&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(JOB_REPORT = JOBNAME and JOBCOUNT = JOBCOUNT and {SCHED_START_DATE = today or SCHED_START_DATE = tomorrow })&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OR takes precedence over and and the statement is not evaluated as above. I thought of writing like code like this to achive my purpose  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT  SINGLE * into corresponding fields of LS_JOB from DTAB
where
JOB_REPORT = JOBNAME and
JOBCOUNT = JOBCOUNT and
SCHED_START_DATE = today .

IF SY-SUBRC NE 0.
SELECT  SINGLE * into corresponding fields of LS_JOB from DTAB
where
JOB_REPORT = JOBNAME and
JOBCOUNT = JOBCOUNT and
SCHED_START_DATE = tomorrow.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a way to do this with a single select statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Nov 2010 12:41:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510621#M1559510</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-11-17T12:41:39Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510622#M1559511</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Why dont you use the BETWEEN operator?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
SELECT  SINGLE * into corresponding fields of LS_JOB from DTAB
where
JOB_REPORT = JOBNAME and
JOBCOUNT = JOBCOUNT and
SCHED_START_DATE BETWEEN today AND tomorrow. 
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Vikranth&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Nov 2010 12:50:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510622#M1559511</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-11-17T12:50:41Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510623#M1559512</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;same effect is achieved with:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;and SCHED_START_DATE in (today, tomorrow).&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Nov 2010 12:51:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510623#M1559512</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-11-17T12:51:39Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510624#M1559513</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SELECT  SINGLE * into corresponding fields of LS_JOB from DTAB&lt;/P&gt;&lt;P&gt;where&lt;/P&gt;&lt;P&gt;JOB_REPORT = JOBNAME and&lt;/P&gt;&lt;P&gt;JOBCOUNT = JOBCOUNT and&lt;/P&gt;&lt;P&gt;( SCHED_START_DATE = today or SCHED_START_DATE = tomorrow ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This should work with paranthesis as written above.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Munish Garg&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Nov 2010 12:52:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510624#M1559513</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-11-17T12:52:39Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510625#M1559514</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;  Write the coding as :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT  SINGLE * into corresponding fields of LS_JOB from DTAB&lt;/P&gt;&lt;P&gt;where&lt;/P&gt;&lt;P&gt;JOB_REPORT = JOBNAME and&lt;/P&gt;&lt;P&gt;JOBCOUNT = JOBCOUNT and&lt;/P&gt;&lt;P&gt;( SCHED_START_DATE = today or &lt;/P&gt;&lt;P&gt;  SCHED_START_DATE = tomorrow ) .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Srini.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Nov 2010 12:58:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510625#M1559514</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-11-17T12:58:31Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510626#M1559515</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It's fairly standard programming practice that when you have a logical expression, that you use brackets to override the default operator precendence.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have you been programming long?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Nov 2010 13:15:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510626#M1559515</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2010-11-17T13:15:19Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510627#M1559516</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Started in ABAP  in recently. &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would not use my C or C++ background....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I do that I will never get past the ABAP compiler....I am trying to not compare them&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Vighneswaran CE on Nov 17, 2010 3:30 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Nov 2010 14:29:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/need-help-with-select-statement/m-p/7510627#M1559516</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-11-17T14:29:15Z</dc:date>
    </item>
  </channel>
</rss>

