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
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Export table to a text file using sqlcmd

Author  Topic 

sparky753
Starting Member

7 Posts

Posted - 2008-03-26 : 15:51:04
How do i use sqlcmd to export the rows in a table to a comma-delimited text file?

Thanks,
Sean

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2008-03-26 : 23:05:54
Use -Q option for query and -o option for output file, you can get details with 'sqlcmd /?' in dos prompt.

By the way, you posted in wrong forum.
Go to Top of Page

sparky753
Starting Member

7 Posts

Posted - 2008-03-27 : 10:29:46
Thanks...I realized that i'd posted in the wrong place after I did...
Go to Top of Page
   

- Advertisement -