f



Re: How to read a period in a variable from a file to SAS dataset #2

On Mon, 28 Jul 2008 02:01:10 -0700, =?ISO-8859-1?Q?Rune_Runnest=F8?=
<rune@FASTLANE.NO> wrote:

>/*
>This is the file with the fileref MYFILE:
>
>---------------------------------------
>DOKTITTEL:  this is the first record
>---------------------------------------
>DOKTITTEL:  .
>---------------------------------------
>DOKTITTEL:  this is the third record
>---------------------------------------
>*/
>
>/*
>I want the second record to be '.', not ' '.
>How can I obtain that?
>
>Rune
>*/
>filename myfile "d:\temp\myfile.txt";
>
>data tp34_jn_dok;
>   length Dokumentbeskrivelse  $40. ;
>   infile myfile dlm=">>>" pad ;
>   input @"DOKTITTEL:" dokumentbeskrivelse ;
>run;

Use the $CHAR informat.
0
hs
7/28/2008 12:50:02 PM
comp.soft-sys.sas 142827 articles. 4 followers. Post Follow

0 Replies
664 Views

Similar Articles

[PageSpeed] 33

Reply: