I have a column that has data type varchar(max). Some rows in that column have long text data. When I copy the SQL result set from that column and paste to excel, the row gets split into multiple rows. I want to past in sunch a way that single cell data from SQL server go to single cell in excel. I am not sure how to fix that problem. Any suggestion would be appreciated. Thank you
Asked
Active
Viewed 9,026 times
0
-
Are you copy/pasting from SQL Server Management Studio? – Seth Moore Aug 28 '13 at 17:56
-
possible duplicate of [Copy And Paste From SQL Server Management Studio 2012 New Line Issue Into Excel](http://stackoverflow.com/questions/13380779/copy-and-paste-from-sql-server-management-studio-2012-new-line-issue-into-excel) – THelper Sep 01 '15 at 08:05
2 Answers
2
Use Excel Import from SQL Server feature. It should import each row of data into a single row in Excel and each column into a single column.

Seth Moore
- 3,575
- 2
- 23
- 33
0
You can try to select data directly into excel spreadsheet.
Check this for more details http://blog.waynesheffield.com/wayne/code-library/ad-hoc-querying/#codesyntax_5

Iza Pastoor
- 192
- 1
- 4