<?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: Format DATE9 in SAS Data Management</title>
    <link>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175596#M3526</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;cesartiburcio,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think the problem is that you are trying to tell it to input a date without specifying some information beforehand. To get the format to be read in correctly and applied I think you will need to specify a length, informat, and format as well as the input statement. Below is some code that should import it correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data maria;&lt;/P&gt;&lt;P&gt;length idvol $7. datevol 8 totalpass 3 poidscargo 5;&lt;/P&gt;&lt;P&gt;informat idvol $7. datevol date9. totalpass BEST3. poidscargo BEST5.;&lt;/P&gt;&lt;P&gt;format idvol $7. datevol date9. totalpass BEST3. poidscargo BEST5.;&lt;/P&gt;&lt;P&gt;infile 'C:\Users\Cesar\Desktop\tpnote\ssd.dat';&lt;/P&gt;&lt;P&gt;input @1 idvol $1-7&amp;nbsp; @40 datevol date9. @64 totalpass BEST3. @68 poidscargo BEST5.;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also make sure that the pointers are going to the right places. When I pulled your data off of your post, the date actually started at 38, but it may have just been the way that I copied and pasted.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 15 Feb 2014 14:58:50 GMT</pubDate>
    <dc:creator>overmar</dc:creator>
    <dc:date>2014-02-15T14:58:50Z</dc:date>
    <item>
      <title>Format DATE9</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175594#M3524</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Im reading some data from a file where the data is in the format 01DEC2010 which actually is the format date9 in SAS. I must read the data from the file and create a table specifiying that the format must be DATE9 but when i try to do so, at my table there is only a "." at the date columnn.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;here is the sintax im using:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data maria;&lt;/P&gt;&lt;P&gt;infile 'C:\Users\Cesar\Desktop\tpnote\ssd.dat';&lt;/P&gt;&lt;P&gt;input idvol $ 1-7&amp;nbsp; @40 datevol DATE9.&amp;nbsp;&amp;nbsp; @64 totalpass 65-67 @68 poidscargo 69-73;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and here are some lines from the file:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;IA112000000112SFOHNDJetCruise LF8100&lt;/TD&gt;&lt;TD&gt;01DEC1999 4&amp;nbsp; 19&amp;nbsp; 31 171 255 61300 79077&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;IA018040000018SFOSEAJetCruise SF1000&lt;/TD&gt;&lt;TD&gt;01DEC1999 4&amp;nbsp; 10&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 123 150 10300 13287&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;IA029010000029SFOHNLJetCruise LF5200&lt;/TD&gt;&lt;TD&gt;02DEC1999 5&amp;nbsp; 13&amp;nbsp; 24 138 207 47400 61146&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can someone help me please?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 15 Feb 2014 08:55:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175594#M3524</guid>
      <dc:creator>cesartiburcio</dc:creator>
      <dc:date>2014-02-15T08:55:18Z</dc:date>
    </item>
    <item>
      <title>Re: Format DATE9</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175595#M3525</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Need more information notes from log.&amp;nbsp; When I copy your records to an editor there are two '0a'x between LF8100 and 01DEC1999 by default SAS will use '0a' as new line.&amp;nbsp; So&amp;nbsp; datevol ain't @40.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 15 Feb 2014 14:58:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175595#M3525</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2014-02-15T14:58:43Z</dc:date>
    </item>
    <item>
      <title>Re: Format DATE9</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175596#M3526</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;cesartiburcio,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think the problem is that you are trying to tell it to input a date without specifying some information beforehand. To get the format to be read in correctly and applied I think you will need to specify a length, informat, and format as well as the input statement. Below is some code that should import it correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data maria;&lt;/P&gt;&lt;P&gt;length idvol $7. datevol 8 totalpass 3 poidscargo 5;&lt;/P&gt;&lt;P&gt;informat idvol $7. datevol date9. totalpass BEST3. poidscargo BEST5.;&lt;/P&gt;&lt;P&gt;format idvol $7. datevol date9. totalpass BEST3. poidscargo BEST5.;&lt;/P&gt;&lt;P&gt;infile 'C:\Users\Cesar\Desktop\tpnote\ssd.dat';&lt;/P&gt;&lt;P&gt;input @1 idvol $1-7&amp;nbsp; @40 datevol date9. @64 totalpass BEST3. @68 poidscargo BEST5.;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also make sure that the pointers are going to the right places. When I pulled your data off of your post, the date actually started at 38, but it may have just been the way that I copied and pasted.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 15 Feb 2014 14:58:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175596#M3526</guid>
      <dc:creator>overmar</dc:creator>
      <dc:date>2014-02-15T14:58:50Z</dc:date>
    </item>
    <item>
      <title>Re: Format DATE9</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175597#M3527</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Actually there are tabs before the date so the date is NOT in column 40.&lt;/P&gt;&lt;P&gt;If you are using the INFILE option EXPANDTABS then the date will start in column 41.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;IA112000000112SFOHNDJetCruise LF8100&amp;nbsp;&amp;nbsp;&amp;nbsp; 01DEC1999 4&amp;nbsp; 19&amp;nbsp; 31 171 255 61300 79077&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;IA018040000018SFOSEAJetCruise SF1000&amp;nbsp;&amp;nbsp;&amp;nbsp; 01DEC1999 4&amp;nbsp; 10&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 123 150 10300 13287&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;IA029010000029SFOHNLJetCruise LF5200&amp;nbsp;&amp;nbsp;&amp;nbsp; 02DEC1999 5&amp;nbsp; 13&amp;nbsp; 24 138 207 47400 61146&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Plus the second line is not going to align for reading the later columns.&amp;nbsp; Since they are separated by spaces anyway I recommend replacing the missing values with period and use list mode input.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;IA112000000112SFOHNDJetCruise LF8100&amp;nbsp;&amp;nbsp;&amp;nbsp; 01DEC1999 4&amp;nbsp; 19&amp;nbsp; 31 171 255 61300 79077&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;IA018040000018SFOSEAJetCruise SF1000&amp;nbsp;&amp;nbsp;&amp;nbsp; 01DEC1999 4&amp;nbsp; 10&amp;nbsp;&amp;nbsp; . 123 150 10300 13287&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;IA029010000029SFOHNLJetCruise LF5200&amp;nbsp;&amp;nbsp;&amp;nbsp; 02DEC1999 5&amp;nbsp; 13&amp;nbsp; 24 138 207 47400 61146&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 15 Feb 2014 15:45:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175597#M3527</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2014-02-15T15:45:59Z</dc:date>
    </item>
    <item>
      <title>Re: Format DATE9</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175598#M3528</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes that was the only problem. the column is the column 41. thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 16 Feb 2014 07:35:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Format-DATE9/m-p/175598#M3528</guid>
      <dc:creator>cesartiburcio</dc:creator>
      <dc:date>2014-02-16T07:35:47Z</dc:date>
    </item>
  </channel>
</rss>

