all groups > sql server dts > january 2006 >
You're in the

sql server dts

group:

Sql 2005: SSIS - How to convert a crazy string to a date


Sql 2005: SSIS - How to convert a crazy string to a date ealmquist NO[at]SPAM gmail.com
1/12/2006 2:38:21 PM
sql server dts:
I'm trying to fix some errors in a SSIS package that occured after
migrating from a SQL 2000 DTS package. I've been fairly successful so
far, but I'm failing miserably on a data conversion. How can I convert
a string formatted as

Jan 11 2006 12:00:00:000AM

to a smalldatetime?

Any help would be greatly appreciated!

-Erik
Re: Sql 2005: SSIS - How to convert a crazy string to a date Allan Mitchell
1/14/2006 5:38:12 AM
Hello ealmquist@gmail.com,


What have you tried so far?

What errors do you receive if any or do you just receive the wrong dates?

One obvious way to do this is to use a Script component

What is the source?

You could also use a derived column and Kirk has some simple examples that
you could extend

http://www.sqljunkies.com/WebLog/knight_reign/archive/2005/07/14/16073.aspx

Allan



[quoted text, click to view]

AddThis Social Bookmark Button