Monday, March 30, 2015

Create a folder in file system using T-SQL

--I) How to create a folder in our file system using T-SQL

DECLARE @SQL VARCHAR(500)
DECLARE @DestPath VARCHAR(200)



SET    @DestPath = 'E\SQLFolder\'
SET    @SQL =    'MKDIR ' + @DestPath +'YourFolderName'

EXEC    xp_cmdshell    @SQL, no_output
PRINT    @SQL
EXEC (@SQL)

Note: Please make sure 'XPCmdSheeEnabled' True.

1 comment:

  1. NJ gambling scene - drmcd
    Casino revenue is a good 평택 출장안마 indicator 춘천 출장마사지 of how 구리 출장마사지 well the NJ online gambling industry is 나주 출장샵 The state is on 천안 출장마사지 an exciting ground to move forward in its efforts to Jan 25, 2022Randy Houser, ‎Maryland

    ReplyDelete