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

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 pipe delimited file

Author  Topic 

w1102157
Yak Posting Veteran

80 Posts

Posted - 2012-02-28 : 10:01:15
How can i export data from a table in sql to a pipe delimited file??

WJHamel
Aged Yak Warrior

651 Posts

Posted - 2012-02-28 : 10:10:18
I use RazorSQL to do such. I believe you can download a time limited trial version.
Go to Top of Page

Transact Charlie
Master Smack Fu Yak Hacker

3451 Posts

Posted - 2012-02-28 : 10:34:27
you can use simply bcp

bcp <Database>.<Schema>.<TableName> out <Filename> -c -t "|" -U<UserName> -P<Password> -S<Server>


Charlie
===============================================================
Msg 3903, Level 16, State 1, Line 1736
The ROLLBACK TRANSACTION request has no corresponding BEGIN TRANSACTION
Go to Top of Page

w1102157
Yak Posting Veteran

80 Posts

Posted - 2012-02-28 : 10:50:16
Msg 102, Level 15, State 1, Line 1
Incorrect syntax near '.'.
Msg 105, Level 15, State 1, Line 1
Unclosed quotation mark after the character string

getting the following error messages
Go to Top of Page

Transact Charlie
Master Smack Fu Yak Hacker

3451 Posts

Posted - 2012-02-28 : 10:52:08
you use bcp from a command line. Not executed from sql.

http://msdn.microsoft.com/en-us/library/ms162802.aspx

Charlie
===============================================================
Msg 3903, Level 16, State 1, Line 1736
The ROLLBACK TRANSACTION request has no corresponding BEGIN TRANSACTION
Go to Top of Page
   

- Advertisement -