|  | Posted by phantom on 09/09/05 03:05 
Greetings,
 I have a sp that dumps text into a textfile but I am having trouble
 creating the textfile.
 
 EXEC master.dbo.xp_cmdShell '\\servername\d$\The File\sub\filename.dat'
 
 The directory "The File" has a space in it.  I've tried putting the
 carat ^ before the space, and putting double quotes...but I keep
 getting this error
 
 '\\servername\d$\The' is not recognized as an internal or external
 command, operable program or batch file.
 
 If I do EXEC master.dbo.xp_cmdShell '"\\servername\d$\The
 File\sub\filename.dat"' I get the same thing.
 
 If I do EXEC master.dbo.xp_cmdShell '""\\servername\d$\The
 File\sub\filename.dat""' I get
 
 '"\\servername\d$\The File\sub\filename.dat"'
 is not recognized as an internal or external command, operable program
 or batch file.
 
 Does anybody see what I am doing wrong?
  Navigation: [Reply to this message] |