I'm trying to optimize an hourly txt file export and reduce the file size on SQL Server 2008 R2.
I created a job which is calling the below BCP:
EXECUTE master.dbo.xp_cmdshell 'BCP "SELECT Columns FROM table queryout D:\OUTPUT\Filename.txt -S Servername -t "|" -T'
Actually the txt file size is around 20MB, is it a way to reduce the size without removing columns or adding a condition in the select? Maybe in the bcp config? Thank you in advance!