Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

bcp date - time question

Status
Not open for further replies.

nikischwabe

Programmer
Jun 9, 2000
14
0
0
AU
I'm having problems getting the BCP to export strings to a tsv file properley.
I have a VARCHAR field in that holds strings like '2002-08-19 13:48:36' (converted from DATETIME to VARCHAR).
It is my understanding that VARCHAR data is essentially a string, however when I use BCP to export, the values get formatted like : 19/08/2002 13:48.

Does anyone know what is going on here?

My BCP call is like:

"SELECT myDateField FROM myTable" queryout data.txt -c
-CACP -Ssvr -Usa -Pxxx

Any pointers would be much apreciated. Nice one :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top