Upload SQL XML file to FTP

Hello,

I had a question about uploading an XML file generated by a SQL server statement to an FTP account.

For example, i have put together a stored procedure that runs a SQL statement and writes to a file that runs each day as a Schedule Job using SQL Server Agent.

Now the last thing i need to do is to be able to upload the outputted file to an FTP account but i’m not entirely sure how to go about doing this. I have looked into Windows scheduler and also Command Line tools but would prefer asking the professionals :wink:

Any ideas anyone?

Kind regards,

Not really a DB question. Probably best asked in a Microsoft-specific forum if you’re looking for a tool that will automate the task for you. Have you tried http://forums.asp.net/ ?

Easiest way would be to execute a command line from the scheduled task. Windows has a FTP client built in (ftp.exe) that can take command files to allow for reasonably complex scenarios such as this.