Please start any new threads on our new site at We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 SSIS and Import/Export (2008)
 export to text not getting delimiters

Author  Topic 

Starting Member

38 Posts

Posted - 2015-03-24 : 14:11:13
Trying to export query results to a pipe delimited text file but not getting delimiters.
These are the steps I'm taking.

query result
sql server
results to text
custom delimiter,|
right click on query pane
results to file
execute query
make file name

A text file's made but with no delimiter whether I pick custom (|) or comma.

How do you get this to work?

Almighty SQL Goddess

38200 Posts

Posted - 2015-03-24 : 14:13:19
I just use bcp: bcp.exe "select * from db1.dbo.table1" queryout c:\temp\queryoutput.txt -Sserver1\instance1 -T -c -t| -r\r\n

Tara Kizer
SQL Server MVP since 2007
Go to Top of Page

- Advertisement -