Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Overcome BCP limitations for output to CSV file Expand / Collapse
Author
Message
Posted Monday, September 24, 2007 2:28 AM
SSChasing Mays

SSChasing MaysSSChasing MaysSSChasing MaysSSChasing MaysSSChasing MaysSSChasing MaysSSChasing MaysSSChasing Mays

Group: General Forum Members
Last Login: Thursday, July 3, 2014 2:36 PM
Points: 631, Visits: 236
Comments posted to this topic are about the item Overcome BCP limitations for output to CSV file


Post #401902
Posted Thursday, February 14, 2008 11:08 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Thursday, February 14, 2008 11:01 PM
Points: 1, Visits: 1
David A. Long (9/24/2007)
Comments posted to this topic are about the item




Here is an easier method to get headers in output file

bcp "(Select 'PIN','Name') UNION ALL (Select Convert(Varchar,PIN),FName From GangadharG.dbo.CustInfo)" queryout out.txt -U sa -P welcome -c -t "|"

-GGSanthosh
Post #456153
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse