dbTalk Databases Forums  

SSIS Script Transformation - dunno how to return a null

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


Discuss SSIS Script Transformation - dunno how to return a null in the microsoft.public.sqlserver.dts forum.



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

Default SSIS Script Transformation - dunno how to return a null - 05-10-2006 , 04:57 PM






I have a Script Transformation task in my SSIS package that nicely
transforms some IBM date format into SQL 2005's date format. Works like
a charm.

I can't figure out how to make it return a NULL value, though. I know
VB has its new handy nullable datatypes, but the script editor chooses
the datatypes based on the properties for the output columns in the
"Script Transformation Editor" dialog. I choose "database date
[DT_DBDATE]" and go on my merry way. There's no obvious way to make it
nullable and I'm not learning anything from the help page nor google.

Am I barking up the right tree? Right now I'm setting what should be
null values to '1900-01-01' and then setting them to NULL with a SQL
script action at the end of my SSIS package, but I'm not looking
forward to clobbering someone else's boneheaded use of special dates.


Reply With Quote
  #2  
Old   
Darren Green
 
Posts: n/a

Default RE: SSIS Script Transformation - dunno how to return a null - 05-12-2006 , 10:50 AM






The column wrapper should have two properties

..ColumName = "fred"

or

..ColumnName_IsNull = true

--
http://wiki.sqlis.com | http://www.sqlis.com | http://www.sqldts.com


"judgmentalist" wrote:

Quote:
I have a Script Transformation task in my SSIS package that nicely
transforms some IBM date format into SQL 2005's date format. Works like
a charm.

I can't figure out how to make it return a NULL value, though. I know
VB has its new handy nullable datatypes, but the script editor chooses
the datatypes based on the properties for the output columns in the
"Script Transformation Editor" dialog. I choose "database date
[DT_DBDATE]" and go on my merry way. There's no obvious way to make it
nullable and I'm not learning anything from the help page nor google.

Am I barking up the right tree? Right now I'm setting what should be
null values to '1900-01-01' and then setting them to NULL with a SQL
script action at the end of my SSIS package, but I'm not looking
forward to clobbering someone else's boneheaded use of special dates.



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.