Moving file to another location using "xp_cmdshell 'NET USE ....."

  • Hi ,

    I want to move/copy one MDB(Ms-access) file from one location to other shared location using

    "xp_cmdshell 'NET USE ..... "

    can anybody tell how can i do it ?

    in next step : i want to encorporate it in SSIS pacakge .

    Please help me.

    -------Bhuvnesh----------
    I work only to learn Sql Server...though my company pays me for getting their stuff done;-)

  • I have had to do this before, pretty simple. See the following...

    xp_cmdshell"net use t: \\10.10.10.10\share_name password_here /user:username_here /persistent:yes"

    /* Add extra code here... */

    xp_cmdshell"net use T: /delete"

  • Thanks alot buddy:-)

    Regards,

    Vijay

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

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