BookmarkSubscribeRSS Feed
Babloo
Rhodochrosite | Level 12

I'm using file writer transformation in my DI job to create the .txt file. After the successful execution of the job, when I tried to open .txt file, I'm getting an error like "Invalid Physical file". Code generated by file writer transformation as follows.

 

data _null_; 
   set &SYSLAST; 
      attrib TBKPAR length = $2; 
      attrib CRI length = $12; 
      attrib P2KBRN length = $2; 
      attrib CRIHIS length = $12; 
      attrib P2KBRH length = $2; 
      attrib SD length = $9; 
      attrib S2KBRN length = $2; 
      attrib XXAROL length = $8; 
      attrib PSI length = $9; 
      attrib HDK length = $3; 
      file "!FSB/common/life_details_crdb_50_tmp_timestamp.txt" lrecl=1226;
      
         put 
             @ 1 TBKPAR  
             @ 3 CRI  
             @ 15 P2KBRN  
             @ 17 CRIHIS  
             @ 29 P2KBRH  
             @ 31 SD  
             @ 40 S2KBRN  
             @ 42 XXAROL  
             @ 50 PSI  
             @ 59 HDK  
         ;
   
run;

Properties of File wrtier transformation:

 

FW.pngFW2.png

 

Appreciate if someone of you help me understand the likely cause for this issue.

1 REPLY 1
LinusH
Tourmaline | Level 20
How do you try to open it?
Almost any text file generated can be opened using standard text editing tools.
Data never sleeps

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

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
  • 1 reply
  • 1727 views
  • 1 like
  • 2 in conversation