DTS Text file Creation and moving to another server i.e SFTP account

  • Hi,

    I have a DTS package working fine. The idea is to create a text file on database server i.e local machine on which DTS would run and then SOMEHOW move this text file to another server to an SFTP folder. The client will access/view this file by using there SFTP account.. How can I do this. I tried xp_cmdshell i.e

    Declare @SQLCMD varchar(500)

    Set @SQLCMD = 'move \\.3\c$\ClientExports\Export.txt, \\.10\d$\Test'

    Exec master.dbo.xp_cmdshell @SQLCMD

    but it didnt work.

    Any suggestions are welcome.. Also I was thinking after the text file creation, having a script or something to move it to destination I want...

  • I think there shouln't be any comma between source and destination path.It should be something like this.

    Set @SQLCMD = 'move \\.3\c$\ClientExports\Export.txt \\.10\d$\Test'

    Thanks,

    SR

     

    Thanks,
    SR

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply