BookmarkSubscribeRSS Feed
gskn4u
Obsidian | Level 7

Hi All,

I am having issue when writing the data into mainframe file.

when I print DATA01, I see no issues. but when I write to output file I get completely different data (not as expected).

The record length is approximately 1200.

can someone please help me.

Best Regards,

DATA _NULL_;                                                      
  FILE OUTFL1 NOPRINT NOTITLES       ;                        
  FORMAT VAR1   VAR2 VAR3 VAR4 VAR5 VAR6       $050     
     VAR7   VAR8 VAR9 VAR10 VAR11 VAR12    $100     
     ;                                                        
  SET DATA01 ;                                                    
  IF _N_ = 1 THEN                                                 

  PUT @001 'VAR1,VAR2,VAR3,VAR4,VAR5,VAR6,VAR7,VAR8,VAR9,VAR10,VAR11,' 

  @058 'VAR12,' ;                                             
  PUT @001 VAR1        $050. '","'                            
  @053 VAR2        $050. '","'  

.

.

.

.

.                         
                                                                  

  ;   

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 0 replies
  • 502 views
  • 0 likes
  • 1 in conversation