May 31, 2012 at 6:49 am
Hi,
Can we compress any file throgh SQL Server
- using bcp, xp_cmdshell?
- using sql_cmd?
- stored procedure?
ex:- saving the query results into file
bcp "select * from [Instance Name].DBNAME.dbo.TableName " queryout "G:\Report.xls" -c -T -x'
Thank you so much, in advance
Phani
May 31, 2012 at 7:13 am
Phani
Sure. If you have WinZip or another such utility installed, you can use xp_cmdshell, which you can also use for the COMPRESS command if you have the Windows Resource Kit. Alternatively, I believe that PowerShell will do compression for you.
John
May 31, 2012 at 7:25 am
Thank you John , let me try this
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy