<?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: Help with &amp;quot;ERROR: Invalid sequence of commands&amp;quot; in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399806#M278514</link>
    <description>&lt;P&gt;Unfortunately, that is not it. Even with these changes, it still results in the same error.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 29 Sep 2017 14:25:54 GMT</pubDate>
    <dc:creator>Jordan_Epi</dc:creator>
    <dc:date>2017-09-29T14:25:54Z</dc:date>
    <item>
      <title>Help with "ERROR: Invalid sequence of commands"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399578#M278508</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My team is making the switch from SAS Desktop 9.4 to server-based SAS Enterprise Guide.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have one piece of fairly simple code that works properly in 9.4, but is is now producing the following error in enterprise guide:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;ERROR: Invalid sequence of commands for file ORACLE.HAVE.DATA&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;data&lt;/STRONG&gt;&amp;nbsp;WORK.WANT; set ORACLE.HAVE;&lt;/P&gt;&lt;P&gt;WHERE (FACILITY in("FACILITY 1", "FACILITY 2", "FACILITY 3", "ETC"))&lt;/P&gt;&lt;P&gt;AND (ER_ADMIT_DATETIME&amp;gt;=&lt;STRONG&gt;'20SEP2017:22:00:00'dt&lt;/STRONG&gt; and ER_ADMIT_DATETIME&amp;lt;&lt;STRONG&gt;'22SEP2017:01:00:00'dt&lt;/STRONG&gt;)&lt;/P&gt;&lt;P&gt;AND ((UPCASE(PATIENT_POSTAL_CODE) contains "T1T1T1") or (UPCASE(PATIENT_POSTAL_CODE) contains "T1T 1T1"));&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;run&lt;/STRONG&gt;;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any ideas what is causing it? It is accessing an Oracle database, if that matters.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Sep 2017 18:39:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399578#M278508</guid>
      <dc:creator>Jordan_Epi</dc:creator>
      <dc:date>2017-09-28T18:39:44Z</dc:date>
    </item>
    <item>
      <title>Re: Help with "ERROR: Invalid sequence of commands"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399580#M278509</link>
      <description>&lt;P&gt;This can't be the actual code. HAVE is not an Oracle database. And your code doesn't reference&amp;nbsp;&lt;SPAN&gt;ARTSSN.ATD_ALL_SITES_LAST30DAYS.DATA.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Show us the actual code used.&lt;/P&gt;</description>
      <pubDate>Thu, 28 Sep 2017 18:34:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399580#M278509</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2017-09-28T18:34:58Z</dc:date>
    </item>
    <item>
      <title>Re: Help with "ERROR: Invalid sequence of commands"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399583#M278510</link>
      <description>&lt;P&gt;Edited the file name in the error to match the data source name.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It is the code used, with facility names removed. Otherwise it is identical.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Sep 2017 18:41:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399583#M278510</guid>
      <dc:creator>Jordan_Epi</dc:creator>
      <dc:date>2017-09-28T18:41:02Z</dc:date>
    </item>
    <item>
      <title>Re: Help with "ERROR: Invalid sequence of commands"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399596#M278511</link>
      <description>&lt;P&gt;Are you doing this in PROC SQL to work with Oracle? Or did you actually run a data step?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Really, the more details you can give us, the quicker you will get and answer, and the better the answer will be.&lt;/P&gt;</description>
      <pubDate>Thu, 28 Sep 2017 19:27:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399596#M278511</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2017-09-28T19:27:36Z</dc:date>
    </item>
    <item>
      <title>Re: Help with "ERROR: Invalid sequence of commands"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399597#M278512</link>
      <description>A data step. I could switch it over to PROC SQL though.</description>
      <pubDate>Thu, 28 Sep 2017 19:29:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399597#M278512</guid>
      <dc:creator>Jordan_Epi</dc:creator>
      <dc:date>2017-09-28T19:29:46Z</dc:date>
    </item>
    <item>
      <title>Re: Help with "ERROR: Invalid sequence of commands"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399678#M278513</link>
      <description>&lt;P&gt;I think this is your problem:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;From your script&lt;/P&gt;&lt;P&gt;WHERE (FACILITY in ("FACILITY 1", "FACILITY 2", "FACILITY 3", "ETC")&lt;FONT size="7"&gt;)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;AND (ER_ADMIT_DATETIME&amp;gt;=&lt;STRONG&gt;'20SEP2017:22:00:00'dt&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;and ER_ADMIT_DATETIME&amp;lt;&lt;STRONG&gt;'22SEP2017:01:00:00'dt&lt;/STRONG&gt;)&lt;/P&gt;&lt;P&gt;AND ((UPCASE(PATIENT_POSTAL_CODE) contains "T1T1T1") or (UPCASE(PATIENT_POSTAL_CODE) contains "T1T 1T1"));&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You abruptly closed your long where statement.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Try this one.....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;WHERE (&lt;BR /&gt;FACILITY in&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ("FACILITY 1", "FACILITY 2", "FACILITY 3", "ETC")&amp;nbsp;&lt;/P&gt;&lt;P&gt;AND (ER_ADMIT_DATETIME&amp;gt;='20SEP2017:22:00:00'dt and ER_ADMIT_DATETIME&amp;lt;'22SEP2017:01:00:00'dt)&lt;BR /&gt;AND&lt;BR /&gt;(&lt;BR /&gt;(UPCASE(PATIENT_POSTAL_CODE) contains "T1T1T1")&lt;BR /&gt;or&lt;BR /&gt;(UPCASE(PATIENT_POSTAL_CODE) contains "T1T 1T1")&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;&lt;FONT size="7"&gt;);&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Assuming that&amp;nbsp;the filter for date and time is correct.&amp;nbsp; I also place more spaces for the "in" i noticed there is no space separating "in(" but i think sas will know and understand but to be safe better put space/s.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 29 Sep 2017 02:14:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399678#M278513</guid>
      <dc:creator>ShiroAmada</dc:creator>
      <dc:date>2017-09-29T02:14:05Z</dc:date>
    </item>
    <item>
      <title>Re: Help with "ERROR: Invalid sequence of commands"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399806#M278514</link>
      <description>&lt;P&gt;Unfortunately, that is not it. Even with these changes, it still results in the same error.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 29 Sep 2017 14:25:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/399806#M278514</guid>
      <dc:creator>Jordan_Epi</dc:creator>
      <dc:date>2017-09-29T14:25:54Z</dc:date>
    </item>
    <item>
      <title>Re: Help with "ERROR: Invalid sequence of commands"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/403211#M278515</link>
      <description>&lt;P&gt;Looks like it is something about the specific data set being referenced. Any data step referring to this table results in the error. Don't know what is causing it yet.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Oct 2017 15:32:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/403211#M278515</guid>
      <dc:creator>Jordan_Epi</dc:creator>
      <dc:date>2017-10-11T15:32:03Z</dc:date>
    </item>
    <item>
      <title>Re: Help with "ERROR: Invalid sequence of commands"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/410237#M278516</link>
      <description>&lt;P&gt;This has been happening to me too in SAS 9.4 M4 lately, no WHERE clause at all.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;PROC SQL;&amp;nbsp; CREATE TABLE X as SELECT * FROM ORALIB.ORAVIEW; QUIT;&lt;/P&gt;&lt;P&gt;but fails in SAS data step:&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;DATA X; SET&amp;nbsp;&lt;SPAN&gt;ORALIB.ORAVIEW; RUN;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;with&amp;nbsp;ERROR: Invalid sequence of commands for file ...and happens on several views now when they seemed to have worked just fine prior to the previous maintenance release.&amp;nbsp;&amp;nbsp;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Nov 2017 14:21:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-with-quot-ERROR-Invalid-sequence-of-commands-quot/m-p/410237#M278516</guid>
      <dc:creator>doogie64</dc:creator>
      <dc:date>2017-11-03T14:21:58Z</dc:date>
    </item>
  </channel>
</rss>

