Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
mikejohnson
Posting Yak Master
153 Posts |
Posted - 2004-12-16 : 10:08:46
|
| here is my code, i don't get an error but it returns null. the commands i'm running run a file transfer program and the file isn't getting uploaded.declare @lb varchar(2)set @lb = char(13) + char(10) declare @command varchar(2000)set @command = ''set @command = @command + 'set statusbat=c:\temp\foo.bat' + @lbset @command = @command + 'del %statusbat%' + @lbset @command = @command + 'c:\program files\valicert\stclient\stclient.exe httpsu://www.securesite.com/ c:\inetpub\test.txt /progress /RemoveOnError /quitWhenDone /statusBAT %statusbat%' + @lbset @command = @command + ':mainloop' + @lbset @command = @command + 'if NOT EXIST %statusbat% goto mainloop' + @lbset @command = @command + 'call %statusbat%' + @lbset @command = @command + 'if NOT "%FileDriveStatus%"=="DONE" goto mainloop' + @lbset @command = @command + 'echo done!!!!' + @lbexec master..xp_cmdshell @command |
|
|
mikejohnson
Posting Yak Master
153 Posts |
Posted - 2004-12-16 : 10:53:46
|
| got it now. just wrote a batch file instead of trying to create the command/batch file on the fly |
 |
|
|
|
|
|