LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (March 2006, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Sat, 18 Mar 2006 00:35:39 +0100
Reply-To:     Mariusz Gromada <mariusz.gromada@WP.PL>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Mariusz Gromada <mariusz.gromada@WP.PL>
Organization: "Portal Gazeta.pl -> http://www.gazeta.pl"
Subject:      Re: Output Issues
Comments: To: sas-l@uga.edu
In-Reply-To:  <1142627707.572205.248140@p10g2000cwp.googlegroups.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

The_Grudge:

> I have the following code to output my data to a text file. > > File "Z:\Information Analysis & Distribution\Projects\Shadow > Billing\Electronic Data\David's SAS Program\SAS Results\Output.txt" > ; > Put @01 IPOP $1. > @02 Cr_Number $7. > @09 PatientLastName $25. > @34 PatientFirstName $15. > @49 BDate yymmddn8. > @57 Sex $2. > @59 Street_Address $50. > @109 City $20. > @129 State $3. > @132 Country $15. > @147 Mailing_Code $9. > @156 HCN $10. > @166 Version $2. > @168 HCNExpireDate > @172 Service_Date $8. > @180 ServiceTime $4. > @184 InstitutionFrom $4. > @188 Doc_Num $5. > @194 Institution > @198 PCSVisitNum $12. > @210 OutofProvHealth $12. > @222 Fee $5. > @227 Units $5. > @232 Index > @235 Dx > @239 Ref_Prov_Num $6. > @245 Ref_Lab_Num $4. > @249 Location $4. > @253 PaymentProg $1. > @254 FeeSubmitted ; > Run; > > I have two questions. Obviously I'm specifying the length of my > character variables, but how do I specify the length for the > currency/numeric values? For example, my last value is "Fee Submitted" > so I need to give it the format of "Dollar27.2" but set it's length to > 8 characters in the text file. > > Also, everything in the output file looks great until I add the last > line "@254 FeeSubmitted;" > At the point SAS writes data to a new line in my text file rather than > continung with new columns. How do I fix this/ >

Hello!

1. Tray

format FeeSubmitted dollar27.2; put FeeSubmitted dollar8.2;

2. This is the LRECL option issue. In the file statement you should set the proper LRECL value (default 256).

Kind regards, Mariusz Gromada


Back to: Top of message | Previous page | Main SAS-L page