<?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: PROC IMPORT encounters problem when contains a &amp;quot; in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280727#M269794</link>
    <description>I tend to say it is a bug rather than lack of options, for ALL information(DLM, GUESSINGROWS,etc.) provided. What's the good reason for the procedure to guess wrong? It is 100% sure. If, say, I specify guessing rows=10, and 11th or later rows went wrong, I can understand. (Or I provide ambiguous DLM and so on) If SAS documents declared the PROC IMPORT used DSD options by default and cannot be turn off, then I can also understand it is just lack of options. If it is an incorrect result out of expectation, then it is a bug.</description>
    <pubDate>Tue, 28 Jun 2016 11:53:09 GMT</pubDate>
    <dc:creator>caibird</dc:creator>
    <dc:date>2016-06-28T11:53:09Z</dc:date>
    <item>
      <title>PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280628#M269772</link>
      <description>&lt;P&gt;Guys,&lt;/P&gt;&lt;P&gt;What's wrong with my code? Thanks.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Raw(txt)：&lt;/STRONG&gt;&lt;BR /&gt;ABC DEF="XXXX,0.000,15.2,19&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Code:&lt;/STRONG&gt;&lt;BR /&gt;libname save 'xxxx;&lt;BR /&gt;&amp;nbsp;filename txt 'xxxx\test.txt';&lt;/P&gt;&lt;P&gt;&amp;nbsp;proc import out=save.test&amp;nbsp; datafile=txt dbms=dlm replace;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; delimiter=',';&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; guessingrows=250;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; datarow=1;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; getnames=no;&lt;BR /&gt;&amp;nbsp;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Result:&lt;/STRONG&gt;&lt;BR /&gt;Var1&lt;BR /&gt;&amp;nbsp;ABC DEF="XXXX&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Expect result:&lt;/STRONG&gt;&lt;BR /&gt;Var1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Var2&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Var3&amp;nbsp; Var4&lt;BR /&gt;&amp;nbsp;ABC DEF="XXXX&amp;nbsp;&amp;nbsp; 0.000&amp;nbsp;&amp;nbsp; 15.2&amp;nbsp;&amp;nbsp; 19&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 02:41:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280628#M269772</guid>
      <dc:creator>caibird</dc:creator>
      <dc:date>2016-06-28T02:41:20Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280644#M269773</link>
      <description>&lt;P&gt;What does the log say? Have you tried increasing GuessingRows?&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 04:31:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280644#M269773</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-06-28T04:31:41Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280647#M269774</link>
      <description>&lt;P&gt;Everything is ok in log.&lt;/P&gt;&lt;P&gt;Obvious it is not guessing row problem, my .txt contains only 1 row.&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 04:37:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280647#M269774</guid>
      <dc:creator>caibird</dc:creator>
      <dc:date>2016-06-28T04:37:09Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280648#M269775</link>
      <description>&lt;P&gt;Copy the code generated by PROC IMPORT from LOG and Paste it in Program Editor and try REMOVE DSD Option .&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 05:03:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280648#M269775</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2016-06-28T05:03:20Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280650#M269776</link>
      <description>&lt;P&gt;Here is the log, I tried to remove DSD, problem still there.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In my main post, I already provide the raw data and code, could anyone help copy/paste/run it to help solve the problem, rather than just saying? Thanks a lot!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;***********************************************************************/&lt;BR /&gt;18&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; data SAVE.TEST&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&lt;BR /&gt;19&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; %let _EFIERR_ = 0; /* set the ERROR detection macro variable */&lt;BR /&gt;20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; infile TXT delimiter = ',' MISSOVER DSD lrecl=32767 ;&lt;BR /&gt;21&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; informat VAR1 $27. ;&lt;BR /&gt;22&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; format VAR1 $27. ;&lt;BR /&gt;23&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; input&lt;BR /&gt;24&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; VAR1 $&lt;BR /&gt;25&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&lt;BR /&gt;26&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if _ERROR_ then call symputx('_EFIERR_',1);&amp;nbsp; /* set ERROR detection macro variable */&lt;BR /&gt;27&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; run;&lt;/P&gt;&lt;P&gt;NOTE: The infile TXT is:&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Filename=xxxx\test.txt,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; RECFM=V,LRECL=32767,File Size (bytes)=27,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Last Modified=28Jun2016:10:02:27,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Create Time=28Jun2016:09:53:48&lt;/P&gt;&lt;P&gt;NOTE: 1 record was read from the infile TXT.&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; The minimum record length was 27.&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; The maximum record length was 27.&lt;BR /&gt;NOTE: The data set SAVE.TEST has 1 observations and 1 variables.&lt;BR /&gt;NOTE: DATA statement used (Total process time):&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.03 seconds&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.03 seconds&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;1 rows created in SAVE.TEST from TXT.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;NOTE: SAVE.TEST data set was successfully created.&lt;BR /&gt;NOTE: The data set SAVE.TEST has 1 observations and 1 variables.&lt;BR /&gt;NOTE: PROCEDURE IMPORT used (Total process time):&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.17 seconds&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.14 seconds&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 05:29:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280650#M269776</guid>
      <dc:creator>caibird</dc:creator>
      <dc:date>2016-06-28T05:29:02Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280653#M269777</link>
      <description>&lt;P&gt;FYI It does help if you post your data in the same format that you have it.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;Data want;&lt;BR /&gt;informat var1 $20.;
Infile txt dlm=',' Truncover ;
Input var1 $ var2 var3 var4;
Run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 28 Jun 2016 05:36:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280653#M269777</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-06-28T05:36:08Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280655#M269778</link>
      <description>&lt;P&gt;Thanks a lot! This does work.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But for some reason, I need to use PROC IMPORT...&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 05:48:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280655#M269778</guid>
      <dc:creator>caibird</dc:creator>
      <dc:date>2016-06-28T05:48:18Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280656#M269779</link>
      <description>&lt;P&gt;Why?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 05:49:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280656#M269779</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-06-28T05:49:53Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280657#M269780</link>
      <description>&lt;P&gt;You didn't remove DSD.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;18&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; data SAVE.TEST&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;19&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; %let _EFIERR_ = 0; /* set the ERROR detection macro variable */&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; infile TXT delimiter = ',' MISSOVER &lt;STRONG&gt;DSD&lt;/STRONG&gt;&amp;nbsp; /* &amp;lt;-- remove it */ &amp;nbsp;lrecl=32767 ;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;21&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; informat VAR1 $27. ;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;22&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; format VAR1 $27. ;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;23&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; input&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;24&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; VAR1 $&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;25&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;26&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if _ERROR_ then call symputx('_EFIERR_',1);&amp;nbsp; /* set ERROR detection macro variable */&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;27&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; run;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 05:50:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280657#M269780</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2016-06-28T05:50:30Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280659#M269781</link>
      <description>&lt;P&gt;I just notice that the code genereated by PROC IMPORT is not right. It miss other two variables.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;filename TXT '/folders/myfolders/test03.txt';&lt;BR /&gt; data TEST ;&lt;BR /&gt; %let _EFIERR_ = 0; /* set the ERROR detection macro variable */&lt;BR /&gt; infile TXT delimiter = ',' MISSOVER lrecl=32767 ;&lt;BR /&gt; informat VAR1 $27. ;&lt;BR /&gt; format VAR1 $27. ;&lt;BR /&gt; input&lt;BR /&gt; VAR1 $&lt;BR /&gt; &lt;STRONG&gt;VAR2 $&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt; VAR3 $&lt;/STRONG&gt;&lt;BR /&gt; ;&lt;BR /&gt; if _ERROR_ then call symputx('_EFIERR_',1); /* set ERROR detection macro variable */&lt;BR /&gt; run;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 05:54:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280659#M269781</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2016-06-28T05:54:54Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280661#M269782</link>
      <description>&lt;P&gt;Try setting guessing row to 1 would be my only guess.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 06:00:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280661#M269782</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-06-28T06:00:28Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280670#M269783</link>
      <description>&lt;P&gt;Well, the reason&amp;nbsp;I tend to use PROC IMPORT is the raw data row length separated by "," is variable.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Besides, I am kind of wondering why PROC IMPORT not work, after all, I specify DLM=',' already, why SAS still need to treat the " special? Isn't it a bug if no solution?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried guessing one row, but not work.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 06:32:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280670#M269783</guid>
      <dc:creator>caibird</dc:creator>
      <dc:date>2016-06-28T06:32:55Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280671#M269784</link>
      <description>&lt;P&gt;I just submitted the log from PROC IMPORT to you guys to help check what maybe the cause.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;While I ran the code, I removed DSD, not work.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The way I most need is someone provide a PROC IMPORT code works for a txt content&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;ABC DEF="XXXX,0.000,15.2,19&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Simply point out what's the problem in my code also great.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Guessing, saying, not much help.&amp;nbsp; (I appreciate the kindness).&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 06:39:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280671#M269784</guid>
      <dc:creator>caibird</dc:creator>
      <dc:date>2016-06-28T06:39:10Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280676#M269785</link>
      <description>&lt;P&gt;Why bother with proc import at all?&lt;/P&gt;
&lt;P&gt;It needs to make a guess, and I guess that is simply confused by the double quote.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data test;
infile '$HOME/test.txt' dlm=',';
length var1 $20;
input var1 $ var2 var3 var4;
run;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;works perfectly well.&lt;/P&gt;
&lt;P&gt;proc print shows this:&lt;/P&gt;
&lt;PRE&gt;Obs        var1         var2    var3    var4

 1     ABC DEF="XXXX      0     15.2     19 
&lt;/PRE&gt;</description>
      <pubDate>Tue, 28 Jun 2016 06:57:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280676#M269785</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2016-06-28T06:57:44Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280680#M269786</link>
      <description>&lt;P&gt;My raw data column(variable) are not a const number, the example is var1-var4, other data could be var1-var2, var1-var100.&lt;/P&gt;&lt;P&gt;&lt;SPAN class="token punctuation"&gt;So I need proc import.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 07:06:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280680#M269786</guid>
      <dc:creator>caibird</dc:creator>
      <dc:date>2016-06-28T07:06:45Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280682#M269787</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/92129"&gt;@caibird&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN class="token punctuation"&gt;So I need proc import.&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;No, you don't.&lt;/P&gt;
&lt;P&gt;proc import is a helper for a quick first shot, but not meant to be used in a production environment, as it will mask changes in input data that will bite you in the behind later on. It also has to make guesses, and these may fail (as you just experience).&lt;/P&gt;
&lt;P&gt;Computers are dumb, and if you let them make your work for you, you must be prepared to live with the consequences.&lt;/P&gt;
&lt;P&gt;For importing data into SAS, rely on clearly defined structures and put those into data steps that do what &lt;STRONG&gt;&lt;U&gt;you&lt;/U&gt;&lt;/STRONG&gt; want, not what the computer thinks you want.&lt;/P&gt;
&lt;P&gt;I repeat: computers are dumb.&lt;/P&gt;
&lt;P&gt;That's why we get paid the big bucks to make them do things that make sense &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 07:19:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280682#M269787</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2016-06-28T07:19:50Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280687#M269788</link>
      <description>&lt;P&gt;I don't need the high road statement at the moment, I need the problem solved. Besides I don't agree with you, see below:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I totally understand program is not as flexible as human brain, that's&amp;nbsp;why I explicitly told it the DLM=','.&lt;/P&gt;&lt;P&gt;I told the PROC IMPORT all the elements needed to separate words, but it still failed, obvious it is human brain problem, either I use it wrong/missing syntax, or the PROC IMPORT has bug.&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 07:40:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280687#M269788</guid>
      <dc:creator>caibird</dc:creator>
      <dc:date>2016-06-28T07:40:02Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280694#M269789</link>
      <description>&lt;P&gt;I'm with you that proc import behaves wrongly because the delimiter=','; statement should make it recognize that there are more columns than only one present. Raise an issue with SAS TS about that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The fact that this bug is already present in my rather old 9.2 shows that it was obviously not caught by anybody for a long time, which illustrates our well-meant advice to NOT rely on proc import for heavy-duty work. Because none of the heavy SAS users use it, or they would have stumbled across this.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In the meantime, follow the advice given and write a working data step for cases where you find those quotes. data step logic is a part of SAS from the very beginning, you won't find many pieces of software that have been so rigorously tested by endusers and therefore are literally bug-free.&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 09:08:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280694#M269789</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2016-06-28T09:08:55Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280695#M269790</link>
      <description>&lt;P&gt;As is, I don't think what you want is possible with proc import, since the DSD option appears by default. This would be correct in 99% of cases. You can contact tech support to verify this.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There are probably ways to automate the generation of the data step code to deal with varying number of variables depending on your rules. But since you need a proc import that won't meet your requirement.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Good Luck.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 09:11:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280695#M269790</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-06-28T09:11:59Z</dc:date>
    </item>
    <item>
      <title>Re: PROC IMPORT encounters problem when contains a "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280697#M269791</link>
      <description>&lt;P&gt;I respectfully disagree that proc import has a bug.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It's a guessing proc and typically the DSD option would be correct.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It would be nice to have the option to suppress that however.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 09:21:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-IMPORT-encounters-problem-when-contains-a-quot/m-p/280697#M269791</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-06-28T09:21:32Z</dc:date>
    </item>
  </channel>
</rss>

