<?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 Import dirty csv data in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450151#M113345</link>
    <description>&lt;P&gt;Hi, I'm trying to import the csv&amp;nbsp;file that I downloaded from Bloomberg. I tried the method that I used before but it does not work properly (Error message in log). I attached the code and screenshot of csv&amp;nbsp;file and SAS result here. Any suggestion for improving the code? Thanks a lot!&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;PROC IMPORT OUT= Bloomberg																/*Import three inventory data*/				
			DATAFILE= "E:\one_drive\OneDrive\Thesis\2017_Xusheng\Update1\1-Price\Data\Inventory\Bloomberg.csv"   
            DBMS=CSV REPLACE;				
     GETNAMES=YES;
     DATAROW=2; 
Run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="CSV file" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/19552i18E40D521B222DF9/image-size/large?v=v2&amp;amp;px=999" role="button" title="1522510123(1).png" alt="CSV file" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;CSV file&lt;/span&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SAS Result" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/19553i38A3DF55D9E2928D/image-size/large?v=v2&amp;amp;px=999" role="button" title="1522510421(1).png" alt="SAS Result" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;SAS Result&lt;/span&gt;&lt;/span&gt;&amp;nbsp;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Log error message" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/19555i3185BE2CED7C410F/image-size/large?v=v2&amp;amp;px=999" role="button" title="1522510637(1).png" alt="Log error message" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Log error message&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Sat, 31 Mar 2018 15:38:57 GMT</pubDate>
    <dc:creator>Xusheng</dc:creator>
    <dc:date>2018-03-31T15:38:57Z</dc:date>
    <item>
      <title>Import dirty csv data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450151#M113345</link>
      <description>&lt;P&gt;Hi, I'm trying to import the csv&amp;nbsp;file that I downloaded from Bloomberg. I tried the method that I used before but it does not work properly (Error message in log). I attached the code and screenshot of csv&amp;nbsp;file and SAS result here. Any suggestion for improving the code? Thanks a lot!&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;PROC IMPORT OUT= Bloomberg																/*Import three inventory data*/				
			DATAFILE= "E:\one_drive\OneDrive\Thesis\2017_Xusheng\Update1\1-Price\Data\Inventory\Bloomberg.csv"   
            DBMS=CSV REPLACE;				
     GETNAMES=YES;
     DATAROW=2; 
Run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="CSV file" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/19552i18E40D521B222DF9/image-size/large?v=v2&amp;amp;px=999" role="button" title="1522510123(1).png" alt="CSV file" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;CSV file&lt;/span&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SAS Result" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/19553i38A3DF55D9E2928D/image-size/large?v=v2&amp;amp;px=999" role="button" title="1522510421(1).png" alt="SAS Result" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;SAS Result&lt;/span&gt;&lt;/span&gt;&amp;nbsp;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Log error message" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/19555i3185BE2CED7C410F/image-size/large?v=v2&amp;amp;px=999" role="button" title="1522510637(1).png" alt="Log error message" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Log error message&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 31 Mar 2018 15:38:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450151#M113345</guid>
      <dc:creator>Xusheng</dc:creator>
      <dc:date>2018-03-31T15:38:57Z</dc:date>
    </item>
    <item>
      <title>Re: Import dirty csv data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450154#M113346</link>
      <description>&lt;P&gt;The only errors your log are showing is when the DATE column contains '#VALUE1' instead of a date.&lt;/P&gt;
&lt;P&gt;Sounds like you could just ignore the errors since they will only result in the DATE column having a missing value.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Otherwise write you own data step to read the CSV file.&amp;nbsp; You will then have complete control over how to handle those values.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PS&amp;nbsp; You posted a picture of a spreadsheet and labeled it a CSV file.&amp;nbsp; A CSV is a text file. Don't post pictures of text, just post the text. It is clearer, smaller and easier than posting photos. And if you do post a photo then post a photo of the actual object and not a version that has been transformed by being read into a program like Excel.&lt;/P&gt;</description>
      <pubDate>Sat, 31 Mar 2018 15:44:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450154#M113346</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2018-03-31T15:44:15Z</dc:date>
    </item>
    <item>
      <title>Re: Import dirty csv data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450157#M113349</link>
      <description>Thank you for replying, yes, I read the error message and did not&lt;BR /&gt;figure out how it affects my result. The date and event names are good but&lt;BR /&gt;the problem is with the numbers. Probably I will just create my own data&lt;BR /&gt;step.&lt;BR /&gt;&lt;BR /&gt;I will keep in mind regarding the posting pictures.&lt;BR /&gt;</description>
      <pubDate>Sat, 31 Mar 2018 15:50:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450157#M113349</guid>
      <dc:creator>Xusheng</dc:creator>
      <dc:date>2018-03-31T15:50:15Z</dc:date>
    </item>
    <item>
      <title>Re: Import dirty csv data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450159#M113350</link>
      <description>&lt;P&gt;We cannot tell from the photos what issues you might have with the numbers. Post just a few rows of the actual data in the CSV file and of that data after PROC IMPORT read them (again as text and not photos) and explain it what way that are not correct.&lt;/P&gt;</description>
      <pubDate>Sat, 31 Mar 2018 15:58:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450159#M113350</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2018-03-31T15:58:02Z</dc:date>
    </item>
    <item>
      <title>Re: Import dirty csv data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450229#M113367</link>
      <description>&lt;P&gt;Try another option.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PROC IMPORT OUT= Bloomberg /*Import three inventory data*/ &lt;BR /&gt; DATAFILE= "E:\one_drive\OneDrive\Thesis\2017_Xusheng\Update1\1-Price\Data\Inventory\Bloomberg.csv" &lt;BR /&gt; DBMS=CSV REPLACE; &lt;BR /&gt; GETNAMES=YES;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;guessingrows=32767;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;DATAROW=2; &lt;BR /&gt;Run;&lt;/P&gt;</description>
      <pubDate>Sun, 01 Apr 2018 11:19:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450229#M113367</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2018-04-01T11:19:48Z</dc:date>
    </item>
    <item>
      <title>Re: Import dirty csv data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450255#M113374</link>
      <description>&lt;P&gt;Thank you, Tom. I've found the problem. It was inside my data. Invalid value in the date column ruins the rest of the data. Thank you.&lt;/P&gt;</description>
      <pubDate>Sun, 01 Apr 2018 18:17:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450255#M113374</guid>
      <dc:creator>Xusheng</dc:creator>
      <dc:date>2018-04-01T18:17:41Z</dc:date>
    </item>
    <item>
      <title>Re: Import dirty csv data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450256#M113375</link>
      <description>&lt;P&gt;Thank you, Ksharp. I've found the problem and fixed that.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 01 Apr 2018 18:18:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Import-dirty-csv-data/m-p/450256#M113375</guid>
      <dc:creator>Xusheng</dc:creator>
      <dc:date>2018-04-01T18:18:24Z</dc:date>
    </item>
  </channel>
</rss>

