LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (March 2012, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 14 Mar 2012 14:35:34 -0400
Reply-To:     Ben Powell <bpowell555@GMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Ben Powell <bpowell555@GMAIL.COM>
Subject:      Re: SAS to DOS UTF-8
Comments: To: Tom Abernathy <tom.abernathy@GMAIL.COM>
Content-Type: text/plain; charset=ISO-8859-1

That's a good idea Tom and may well work - I'll try it out :)

On Mon, 12 Mar 2012 12:57:15 -0400, Tom Abernathy <tom.abernathy@GMAIL.COM> wrote:

>Can you work around it by having DOS write the directory output to a file? > >filename foo temp; >options noxwait; >x dir &qsource /t:w /a:-d > "%sysfunc(pathname(foo))" ; >... >infile foo encoding='utf-8'; >... > > >On Mon, 12 Mar 2012 12:38:18 -0400, Ben Powell <bpowell555@GMAIL.COM> wrote: > >>Hi, yes see below. I tried that and it seems to error on the pipe engine, >> >> >>http://support.sas.com/documentation/cdl/ en/lrdict/64316/HTML/default/viewe >r.htm#a000146932.htm >> >> >>3643 filename foo pipe "dir "&qsource" / t:w /a:-d"; >>3644 >>3645 data f; >>3646 retain flag; >>3647 length f $1056.; >>3648 format last_mod_date date9.; >>3649 infile foo encoding="utf-8" dlm="¬"; >> -------- >> 23 >>ERROR 23-2: Invalid option name ENCODING. >> >> >> >>Regards >> >>On Mon, 12 Mar 2012 12:21:08 -0400, Tom Abernathy <tom.abernathy@GMAIL.COM> >>wrote: >> >>>Did you try adding the ENCODING option to the FILENAME statement? >>> >>>On Mon, 12 Mar 2012 11:38:08 -0400, Ben Powell <bpowell555@GMAIL.COM> >wrote: >>> >>>>Hi List, >>>> >>>>I've found pipe and 'sysexec copy' do not maintain utf-8 encoded file >names >>>>such as Andalucia with an accent on the I. >>>> >>>>If I have the correct filenames in a sas dataset the copy works but the >>>>paste pastes an incorrectly resolved filename. >>>> >>>>Using pipe to get dir contents, the resultant dataset gets a filename but >>>>its incorrect. >>>> >>>>As I only have three exceptions I've hardcoded some tranwrds, but would >be >>>>interested to know if this is addressed somewhere. The encoding option >for >>>>instance does not work with the pipe filename. >>>> >>>>/* Neither of the below handle UTF-8 correctly */ >>>>filename foo pipe "dir "&qsource" /t:w / a:-d"; >>>>%sysExec copy &source &destination; >>>> >>>>Is this a dos limitation? >>>> >>>>Regards


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