<?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 Proc SQL error in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Proc-SQL-error/m-p/14011#M2133</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;From your log I can't tell what the initial warnings are about but, regarding the proc sql code, you have two statements:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="background-color: #eef4f9; font-size: 10pt; color: #000080; font-family: 'Courier New';"&gt;&lt;STRONG style="font-size: 10pt;"&gt;&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;22 on AW.ACCT_NO=put(AR.AR_LOCAL_ID, $12.)&lt;/P&gt;&lt;P&gt;23 where AW.ACCT_NO=put(AR.AR_LOCAL_ID, $12.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;STRONG style="color: #000080; font-size: 10pt; background-color: #eef4f9; font-family: 'Courier New';"&gt;&lt;P&gt;If aw.acct_no and ar.ar_local_id are both numbers, why are you converting the latter one to be character?&amp;nbsp; They must both be of the same type.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;STRONG style="color: #000080; font-size: 10pt; background-color: #eef4f9; font-family: 'Courier New';"&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;STRONG style="color: #000080; font-size: 10pt; background-color: #eef4f9; font-family: 'Courier New';"&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;STRONG style="color: #000080; font-size: 10pt; background-color: #eef4f9; font-family: 'Courier New';"&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;STRONG style="background-color: #eef4f9; font-size: 10pt; color: #000080; font-family: 'Courier New';"&gt;&lt;STRONG style="font-size: 10pt;"&gt;&lt;P&gt;&lt;STRONG style="background-color: #eef4f9; font-size: 10pt; color: #000080; font-family: 'Courier New';"&gt;&lt;STRONG style="font-size: 10pt;"&gt; &lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 14 Dec 2011 05:47:39 GMT</pubDate>
    <dc:creator>art297</dc:creator>
    <dc:date>2011-12-14T05:47:39Z</dc:date>
    <item>
      <title>Proc SQL error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Proc-SQL-error/m-p/14010#M2132</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi all, I'm trying to get the below code to run but keep getting the same error - any suggestions on what im doing wrong?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;code :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; color: #000080; font-size: 10pt; font-family: Courier New;"&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;proc sql;&lt;/P&gt;&lt;P&gt;create table mrg_tst as&lt;/P&gt;&lt;P&gt;select AW.*&lt;/P&gt;&lt;P&gt;,AR.AR_ID&lt;/P&gt;&lt;P&gt;,AR.AR_LOCAL_ID&lt;/P&gt;&lt;P&gt;from All_WatchList AW &lt;/P&gt;&lt;P&gt;left join &lt;/P&gt;&lt;P&gt;API5AFS.AR_TRANSLATION AR&lt;/P&gt;&lt;P&gt;on AW.ACCT_NO=put(AR.AR_LOCAL_ID, $12.)&lt;/P&gt;&lt;P&gt;where AW.ACCT_NO=put(AR.AR_LOCAL_ID, $12.)&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;quit;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;STRONG&gt;&lt;SPAN style="font-size: 10pt; color: #000080; font-family: Courier New;"&gt;&lt;SPAN style="color: #000080; font-size: 10pt; font-family: Courier New;"&gt;&lt;P&gt;&lt;/P&gt;&lt;/SPAN&gt;&lt;P&gt;Error Log - &lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; color: #000080; font-size: 10pt; font-family: Courier New;"&gt;&lt;STRONG style="color: #000080; font-size: 10pt; font-family: Courier New;"&gt;﻿&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; color: #000080; font-size: 10pt; font-family: Courier New;"&gt;&lt;STRONG style="color: #000080; font-size: 10pt; font-family: Courier New;"&gt;﻿&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;;*';*";*/;quit;run;&lt;/P&gt;&lt;P&gt;2 OPTIONS PAGENO=MIN;&lt;/P&gt;&lt;P&gt;3 %LET _CLIENTTASKLABEL=%NRBQUOTE(Code);&lt;/P&gt;&lt;P&gt;4 %LET _EGTASKLABEL=%NRBQUOTE(Code);&lt;/P&gt;&lt;P&gt;5 %LET _CLIENTPROJECTNAME=%NRBQUOTE(G:\Portfolio Management\Small Business Collections\SAS\Daily ESBC Account Refresh.egp);&lt;/P&gt;&lt;P&gt;6 %LET _SASPROGRAMFILE=;&lt;/P&gt;&lt;P&gt;7 &lt;/P&gt;&lt;P&gt;8 ODS _ALL_ CLOSE;&lt;/P&gt;&lt;P&gt;NOTE: Some of your options or statements may not be supported with the Activex or Java series of devices. Graph defaults for these &lt;/P&gt;&lt;P&gt;drivers may be different from other SAS/GRAPH device drivers. For further information, please contact Technical Support.&lt;/P&gt;&lt;P&gt;9 OPTIONS DEV=ACTIVEX;&lt;/P&gt;&lt;P&gt;10 FILENAME EGHTML TEMP;&lt;/P&gt;&lt;P&gt;NOTE: Writing HTML(EGHTML) Body file: EGHTML&lt;/P&gt;&lt;P&gt;11 ODS HTML(ID=EGHTML) FILE=EGHTML ENCODING='utf-8' STYLE=EGDefault&lt;/P&gt;&lt;P&gt;11 ! STYLESHEET=(URL="file:///C:/Program%20Files/SAS/Shared%20Files/BIClientStyles/EGDefault.css")&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;11 ! ATTRIBUTES=("CODEBASE"="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://www2.sas.com/codebase/graph/v91/sasgraph.exe"&gt;http://www2.sas.com/codebase/graph/v91/sasgraph.exe&lt;/A&gt;&lt;SPAN&gt;") NOGTITLE NOGFOOTNOTE GPATH=&amp;amp;sasworklocation&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;11 ! ;&lt;/P&gt;&lt;P&gt;12 &lt;/P&gt;&lt;P&gt;13 %gaccessible;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;14 proc sql;&lt;/P&gt;&lt;P&gt;15 create table mrg_tst as&lt;/P&gt;&lt;P&gt;16 select AW.*&lt;/P&gt;&lt;P&gt;17 ,AR.AR_ID&lt;/P&gt;&lt;P&gt;18 ,AR.AR_LOCAL_ID&lt;/P&gt;&lt;P&gt;19 from All_WatchList AW&lt;/P&gt;&lt;P&gt;20 left join&lt;/P&gt;&lt;P&gt;21 API5AFS.AR_TRANSLATION AR&lt;/P&gt;&lt;P&gt;22 on AW.ACCT_NO=put(AR.AR_LOCAL_ID, $12.)&lt;/P&gt;&lt;P&gt;23 where AW.ACCT_NO=put(AR.AR_LOCAL_ID, $12.)&lt;/P&gt;&lt;P&gt;24 ;&lt;/P&gt;&lt;P&gt;ERROR: Expression using equals (=) has components that are of different data types.&lt;/P&gt;&lt;P&gt;ERROR: Expression using equals (=) has components that are of different data types.&lt;/P&gt;&lt;P&gt;NOTE: PROC SQL set option NOEXEC and will continue to check the syntax of statements.&lt;/P&gt;&lt;P&gt;25 quit;&lt;/P&gt;&lt;P&gt;NOTE: The SAS System stopped processing this step because of errors.&lt;/P&gt;&lt;P&gt;NOTE: PROCEDURE SQL used (Total process time):&lt;/P&gt;&lt;P&gt;real time 0.01 seconds&lt;/P&gt;&lt;P&gt;cpu time 0.00 seconds&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;26 &lt;/P&gt;&lt;P&gt;27 %LET _CLIENTTASKLABEL=;&lt;/P&gt;&lt;P&gt;28 %LET _EGTASKLABEL=;&lt;/P&gt;&lt;P&gt;29 %LET _CLIENTPROJECTNAME=;&lt;/P&gt;&lt;P&gt;30 %LET _SASPROGRAMFILE=;&lt;/P&gt;&lt;P&gt;31 &lt;/P&gt;&lt;P&gt;32 ;*';*";*/;quit;run;&lt;/P&gt;&lt;P&gt;33 ODS _ALL_ CLOSE;&lt;/P&gt;&lt;P&gt;34 &lt;/P&gt;&lt;P&gt;35 &lt;/P&gt;&lt;P&gt;36 QUIT; RUN;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; color: #000080; font-size: 10pt; font-family: Courier New;"&gt;&lt;STRONG style="color: #000080; font-size: 10pt; font-family: Courier New;"&gt;﻿&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; color: #000080; font-size: 10pt; font-family: Courier New;"&gt;&lt;STRONG style="color: #000080; font-size: 10pt; font-family: Courier New;"&gt;﻿&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/SPAN&gt;&lt;P&gt;&lt;SPAN style="color: #000080; font-size: 10pt; font-family: Courier New;"&gt; &lt;/SPAN&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;SPAN style="font-size: 10pt; color: #000080; font-family: Courier New;"&gt;&lt;SPAN style="color: #000080; font-size: 10pt; font-family: Courier New;"&gt; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Dec 2011 04:51:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Proc-SQL-error/m-p/14010#M2132</guid>
      <dc:creator>Wickywick</dc:creator>
      <dc:date>2011-12-14T04:51:44Z</dc:date>
    </item>
    <item>
      <title>Proc SQL error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Proc-SQL-error/m-p/14011#M2133</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;From your log I can't tell what the initial warnings are about but, regarding the proc sql code, you have two statements:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="background-color: #eef4f9; font-size: 10pt; color: #000080; font-family: 'Courier New';"&gt;&lt;STRONG style="font-size: 10pt;"&gt;&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;22 on AW.ACCT_NO=put(AR.AR_LOCAL_ID, $12.)&lt;/P&gt;&lt;P&gt;23 where AW.ACCT_NO=put(AR.AR_LOCAL_ID, $12.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;STRONG style="color: #000080; font-size: 10pt; background-color: #eef4f9; font-family: 'Courier New';"&gt;&lt;P&gt;If aw.acct_no and ar.ar_local_id are both numbers, why are you converting the latter one to be character?&amp;nbsp; They must both be of the same type.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;STRONG style="color: #000080; font-size: 10pt; background-color: #eef4f9; font-family: 'Courier New';"&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;STRONG style="color: #000080; font-size: 10pt; background-color: #eef4f9; font-family: 'Courier New';"&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;STRONG style="color: #000080; font-size: 10pt; background-color: #eef4f9; font-family: 'Courier New';"&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;STRONG style="background-color: #eef4f9; font-size: 10pt; color: #000080; font-family: 'Courier New';"&gt;&lt;STRONG style="font-size: 10pt;"&gt;&lt;P&gt;&lt;STRONG style="background-color: #eef4f9; font-size: 10pt; color: #000080; font-family: 'Courier New';"&gt;&lt;STRONG style="font-size: 10pt;"&gt; &lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Dec 2011 05:47:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Proc-SQL-error/m-p/14011#M2133</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2011-12-14T05:47:39Z</dc:date>
    </item>
    <item>
      <title>Proc SQL error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Proc-SQL-error/m-p/14012#M2134</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;apologies should have been a bit clearer before, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ar.ar_local_id is character and aw.acct_no is numeric.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Dec 2011 05:50:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Proc-SQL-error/m-p/14012#M2134</guid>
      <dc:creator>Wickywick</dc:creator>
      <dc:date>2011-12-14T05:50:28Z</dc:date>
    </item>
    <item>
      <title>Proc SQL error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Proc-SQL-error/m-p/14013#M2135</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;proc sql; create table mrg_tst as select AW.* ,AR.AR_ID ,AR.AR_LOCAL_ID from All_WatchList AW left join API5AFS.AR_TRANSLATION AR on AW.ACCT_NO=input(AR.AR_LOCAL_ID, 12.) where AW.ACCT_NO=input(AR.AR_LOCAL_ID,12.) ;quit; Try this&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Dec 2011 06:07:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Proc-SQL-error/m-p/14013#M2135</guid>
      <dc:creator>R_Win</dc:creator>
      <dc:date>2011-12-14T06:07:47Z</dc:date>
    </item>
  </channel>
</rss>

