Sql-server – File size when extracting from SQL Server to CSV

bcpcsvexportsql serversql server 2014

I am attempting to extract a table to CSV using BCP from SQL Server 2014 and the size of the file once the data is extracted is actually larger than the size of the database itself.

One thing to note is that one of the fields in this table is an nvarchar(max) and could contain values that exceed 8000 chars.

I was just wondering if this was normal behavior when extracting this type of data to file, or whether there was some trick that I could use to shrink the file size without any data loss.

Best Answer

Native format (-n) is the most compact, and best if you're moving from one SQL Server to another. The files will also zip quite nicely.