Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

need help on SAS, new line is coming in a column

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IBM Tools
View previous topic :: :: View next topic  
Author Message
sushidas
Warnings : 2

New User


Joined: 23 Aug 2006
Posts: 13

PostPosted: Thu Jan 31, 2013 12:41 am    Post subject: need help on SAS, new line is coming in a column
Reply with quote

Hello,

I am written below code to create s xls output with 3 tabs, my xls with 3 tabs are getting created successgully, only issue is that field COVERAGETYPE is not getting displayed like other columns though it has values. The reason looks like it has newline. I have attached the spreadshhet for the reference, please see the COVERAGETYPE field in 1st and 3 rd tab.

Can someone please advise, how can I either remove this newline from COVERAGETYPE column or else add new line to each column.

Code:
DATA ONNMS;                                               
INFILE SASIN;                                             
                                                           
INPUT                                                     
      SUBSID  $14-23 LASTNAME $43-67 FIRSTNAME $26-40     
      GROUP $70-75 SUBGROUP $78-80 COVERAGETYPE $85-93     
      EFFECTIVEDATE $96-103;                               
                                                           
  IF _N_ < 5 THEN DELETE;                                 
                                                           
DATA ONLOCAL;                                             
INFILE SASIN2;                                             
                                                           
INPUT                                                     
      SUBSID   $57-65 COVERAGE $14-20 LASTNAME $35-48     
      FIRSTNAME $23-32 MI $51-51;                         
                                                           
  IF _N_ < 6 THEN DELETE;                                 
                                                           
DATA ONCOB;                                               
INFILE SASIN3;                                             
INPUT                                                           
      SUBSID  $3-12 LASTNAME $31-55 FIRSTNAME $14-28           
      GROUP $58-63 SUBGROUP $66-68 COVERAGETYPE $73-81         
      EFFECTIVEDATE $84-91 COBRAINDICATOR $96-96;               
                                                               
  IF _N_ < 5 THEN DELETE;                                       
                                                               
  ODS LISTING CLOSE;                                           
  ODS TAGSETS.EXCELXP BODY="W061229"                           
    PATH =O1PDSE(URL=NONE)                                     
    RECORD_SEPERATOR=NONE;                                     
  RUN;                                                         
                                                               
  PROC PRINT DATA=ONNMS NOOBS;                                 
  VAR SUBSID  / STYLE={TAGATTR="\0000000000"};                 
  VAR LASTNAME FIRSTNAME;                                       
  VAR GROUP  / STYLE={TAGATTR="\000000"};                       
  VAR SUBGROUP  / STYLE={TAGATTR="\000"};                       
  VAR COVERAGETYPE EFFECTIVEDATE;                               
  RUN;                                                         
                                                               
  PROC PRINT DATA=ONLOCAL NOOBS;                               
  VAR SUBSID  / STYLE={TAGATTR="\000000000"};                   
  VAR COVERAGE  LASTNAME;                                       
  VAR FIRSTNAME MI;                                             
  RUN;                                                         
                                                               
  PROC PRINT DATA=ONCOB NOOBS;                                 
  VAR SUBSID  / STYLE={TAGATTR="\0000000000"};                 
  VAR LASTNAME;                                                 
  VAR FIRSTNAME;                                               
  VAR GROUP  / STYLE={TAGATTR="\000000"};                       
  VAR SUBGROUP  / STYLE={TAGATTR="\000"};                       
  VAR COVERAGETYPE;                                             
  VAR EFFECTIVEDATE COBRAINDICATOR;                             
  RUN;                                                         
    ODS TAGSETS.EXCELXP CLOSE;                                 
  ODS TAGSETS.EXCELXP CLOSE;   
  ODS LISTING ;               
RUN;
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10210
Location: italy

PostPosted: Thu Jan 31, 2013 1:48 am    Post subject: Reply to: need help on SAS, new line is coming in a column
Reply with quote

do not post attachment very few people are able to download and see them.
the attachment was deleted and Your topic was edited to provide better readability using the code tags
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1458
Location: Azeroth

PostPosted: Thu Jan 31, 2013 12:20 pm    Post subject:
Reply with quote

Enrico,
With all due respect, If the TS is generating an Excel file and wants to explain the scenario, the only possibility is to post the Excel, even a screenshot/copy paste of text wont help since the underlying XML has to be looked at.
Quote:
the attachment was deleted
Now no one can see it :-(
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IBM Tools All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts DB2 query Using Recursion, Converting... smilewithashu2 DB2 1 Tue Jan 03, 2017 12:50 pm
No new posts SQZ pipe delimited file with 1 column... Rick Silvers DFSORT/ICETOOL 2 Sun Nov 06, 2016 8:11 pm
This topic is locked: you cannot edit posts or make replies. Checking wether a string starts from ... sundaram.naveen CLIST & REXX 9 Thu Oct 06, 2016 11:56 am
No new posts Insert Lines in JCL with Rexx after a... Willy Jensen CLIST & REXX 3 Tue Aug 30, 2016 4:18 pm
No new posts Add system date inside of a PS file a... pramitdas DFSORT/ICETOOL 5 Sun Aug 28, 2016 12:06 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us