|Date: ||Fri, 29 Mar 2002 00:34:24 -0500|
|Reply-To: ||"Richard A. DeVenezia" <radevenz@IX.NETCOM.COM>|
|Sender: ||"SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>|
|From: ||"Richard A. DeVenezia" <radevenz@IX.NETCOM.COM>|
|Organization: ||MindSpring Enterprises|
|Subject: ||Re: Windows -- Using PIPES & 8.3 Filenames|
"muon33" <email@example.com> wrote in message
> I've got a question on using pipes to create a SAS dataset of files on a
> windows operating system. The basic question is if it's possible to use
> 'long' windows directory names in the command.
> This filename statement gives me a "Stderr output: The system cannot find
> the path specified." error in the log, when I try to read the pipe:
> filename dirfiles pipe "dir C:\Documents and Settings\michael\My
> Documents\Campaigns /b /s";
> This statement, however, works fine:
> filename dirfiles pipe "dir C:\DOCUME~1\MICHAEL\MYDOCU~1\CAMPAI~1 /b /s";
> Is there an easy way to get this to recognize the long windows directory
> names? It's a pain to figure out the 8.3 equivalent for each directory
> which I'll need to run this.
Since the operating system path contains spaces it must be quoted.
filename dirfiles pipe 'dir "C:\Documents and Settings\michael\My
Documents\Campaigns" /b /s';
filename dirfiles pipe "dir ""C:\Documents and Settings\michael\My
Documents\Campaigns"" /b /s";
Remember, double quotes can be placed in a double quoted string by doubling
them up :)
Richard A. DeVenezia
Need long HTML Titles and Footnotes ?