Prev: Wait Stats on SQL2005
Next: Problem with MS DTC on SQL2008 win server 2k8 with linked server from sql2000 wi
From: Muhammad Bilal on 13 Jan 2010 02:55 Hi. I have a column of datatype datetime in sql server 2000. Problem is when i export tha data of the table through BCP the date format is in the exported file is 2008-01-16 00:00:00.000. I want tha format to be like 16/01/2008. Regards, Muhammad Bilal
From: Erland Sommarskog on 13 Jan 2010 03:45
Muhammad Bilal (MuhammadBilal(a)discussions.microsoft.com) writes: > I have a column of datatype datetime in sql server 2000. > Problem is when i export tha data of the table through BCP the date format > is in the exported file is 2008-01-16 00:00:00.000. > I want tha format to be like 16/01/2008. In such you need to use a query where you convert the datetime value to the desired format, and the use the queryout option to export the data from that query. -- Erland Sommarskog, SQL Server MVP, esquel(a)sommarskog.se Links for SQL Server Books Online: SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx |