DATA Step, Macro, Functions and more

SAS Mainframes SMTP email csv file

Reply
New Contributor
Posts: 2

SAS Mainframes SMTP email csv file

Hi,

 

I am emailiing  mainframe PS file as  attachment in excel file format.

the excel file name is more than 31 chars for ex ."Test format pro marketing - All - time test data for verification".

 

when i opened the file using excel the work book name is proper,however sheet is truncated at 31 char for ex "Test format pro marketing - All - t"

 

How to set the excel sheet name different from theexcel  work book while sending email attachemnt from mainframes.

 

Please suggest.

Super User
Posts: 6,977

Re: SAS Mainframes SMTP email csv file

The maximum length of a worksheet name in Excel is 31 characters, period. No way around that.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
New Contributor
Posts: 2

Re: SAS Mainframes SMTP email csv file

Hi,

Thanks for quick response..

is it possible to set workbook name and sheet name different..

for a given Mainframe file name - test.sample

 

for ex. work book name as sample.xlsx

worksheet name as sheettest

 

Thanks

Mallik

Super User
Posts: 6,977

Re: SAS Mainframes SMTP email csv file

I have no idea if libname xlsx works on a mainframe; if it does (SAS/ACCESS to PC Files must be installed and licensed), you can treat the workbook like a SAS library, and each "dataset" written to it will be a sheet.

How you address a Excel file on the mainframe is a different beast, though. See "z/OS file catalog".

 

FWIW, I never ever export to Excel directly, I always use csv as transfer format. Textuality rules. Let the recipients cobble the data together in Excel, if they want.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Ask a Question
Discussion stats
  • 3 replies
  • 89 views
  • 0 likes
  • 2 in conversation