dbTalk Databases Forums  

export date column

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss export date column in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Pingx
 
Posts: n/a

Default export date column - 03-02-2008 , 12:31 PM






Hi,

I'm trying to export a table to a flat file. the date column showed up like
this in the flat file
2007-05-31 13:02:39.777000000

This caused a problem during import to MYSQL.

How do I get rid of the trailing .777000000 during the export so it appears
like
2007-05-31 13:02:39


Thanks in advance.

Pingx


Reply With Quote
  #2  
Old   
lonnye
 
Posts: n/a

Default RE: export date column - 03-12-2008 , 04:44 PM






What is your select statement for the query?
Have you tried converting the data with :

Convert(varchar(19), YOURDATEFIELD)

This will convert the date into a string... cutting off anything after the
time.
--
~lb


"Pingx" wrote:

Quote:
Hi,

I'm trying to export a table to a flat file. the date column showed up like
this in the flat file
2007-05-31 13:02:39.777000000

This caused a problem during import to MYSQL.

How do I get rid of the trailing .777000000 during the export so it appears
like
2007-05-31 13:02:39


Thanks in advance.

Pingx


Reply With Quote
  #3  
Old   
lonnye
 
Posts: n/a

Default RE: export date column - 03-12-2008 , 04:44 PM



What is your select statement for the query?
Have you tried converting the data with :

Convert(varchar(19), YOURDATEFIELD)

This will convert the date into a string... cutting off anything after the
time.
--
~lb


"Pingx" wrote:

Quote:
Hi,

I'm trying to export a table to a flat file. the date column showed up like
this in the flat file
2007-05-31 13:02:39.777000000

This caused a problem during import to MYSQL.

How do I get rid of the trailing .777000000 during the export so it appears
like
2007-05-31 13:02:39


Thanks in advance.

Pingx


Reply With Quote
  #4  
Old   
lonnye
 
Posts: n/a

Default RE: export date column - 03-12-2008 , 04:44 PM



What is your select statement for the query?
Have you tried converting the data with :

Convert(varchar(19), YOURDATEFIELD)

This will convert the date into a string... cutting off anything after the
time.
--
~lb


"Pingx" wrote:

Quote:
Hi,

I'm trying to export a table to a flat file. the date column showed up like
this in the flat file
2007-05-31 13:02:39.777000000

This caused a problem during import to MYSQL.

How do I get rid of the trailing .777000000 during the export so it appears
like
2007-05-31 13:02:39


Thanks in advance.

Pingx


Reply With Quote
  #5  
Old   
lonnye
 
Posts: n/a

Default RE: export date column - 03-12-2008 , 04:44 PM



What is your select statement for the query?
Have you tried converting the data with :

Convert(varchar(19), YOURDATEFIELD)

This will convert the date into a string... cutting off anything after the
time.
--
~lb


"Pingx" wrote:

Quote:
Hi,

I'm trying to export a table to a flat file. the date column showed up like
this in the flat file
2007-05-31 13:02:39.777000000

This caused a problem during import to MYSQL.

How do I get rid of the trailing .777000000 during the export so it appears
like
2007-05-31 13:02:39


Thanks in advance.

Pingx


Reply With Quote
  #6  
Old   
lonnye
 
Posts: n/a

Default RE: export date column - 03-12-2008 , 04:44 PM



What is your select statement for the query?
Have you tried converting the data with :

Convert(varchar(19), YOURDATEFIELD)

This will convert the date into a string... cutting off anything after the
time.
--
~lb


"Pingx" wrote:

Quote:
Hi,

I'm trying to export a table to a flat file. the date column showed up like
this in the flat file
2007-05-31 13:02:39.777000000

This caused a problem during import to MYSQL.

How do I get rid of the trailing .777000000 during the export so it appears
like
2007-05-31 13:02:39


Thanks in advance.

Pingx


Reply With Quote
  #7  
Old   
lonnye
 
Posts: n/a

Default RE: export date column - 03-12-2008 , 04:44 PM



What is your select statement for the query?
Have you tried converting the data with :

Convert(varchar(19), YOURDATEFIELD)

This will convert the date into a string... cutting off anything after the
time.
--
~lb


"Pingx" wrote:

Quote:
Hi,

I'm trying to export a table to a flat file. the date column showed up like
this in the flat file
2007-05-31 13:02:39.777000000

This caused a problem during import to MYSQL.

How do I get rid of the trailing .777000000 during the export so it appears
like
2007-05-31 13:02:39


Thanks in advance.

Pingx


Reply With Quote
  #8  
Old   
lonnye
 
Posts: n/a

Default RE: export date column - 03-12-2008 , 04:44 PM



What is your select statement for the query?
Have you tried converting the data with :

Convert(varchar(19), YOURDATEFIELD)

This will convert the date into a string... cutting off anything after the
time.
--
~lb


"Pingx" wrote:

Quote:
Hi,

I'm trying to export a table to a flat file. the date column showed up like
this in the flat file
2007-05-31 13:02:39.777000000

This caused a problem during import to MYSQL.

How do I get rid of the trailing .777000000 during the export so it appears
like
2007-05-31 13:02:39


Thanks in advance.

Pingx


Reply With Quote
  #9  
Old   
lonnye
 
Posts: n/a

Default RE: export date column - 03-12-2008 , 04:44 PM



What is your select statement for the query?
Have you tried converting the data with :

Convert(varchar(19), YOURDATEFIELD)

This will convert the date into a string... cutting off anything after the
time.
--
~lb


"Pingx" wrote:

Quote:
Hi,

I'm trying to export a table to a flat file. the date column showed up like
this in the flat file
2007-05-31 13:02:39.777000000

This caused a problem during import to MYSQL.

How do I get rid of the trailing .777000000 during the export so it appears
like
2007-05-31 13:02:39


Thanks in advance.

Pingx


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.