May 11, 2011 at 7:35 pm
I have flat file as source... SQL server is destination ...
I am using ssis package to load the data in sql
I have a problem with 0000-00-00........
I am using ragged right as flat file source.....
In flat file ....datatype is string.........and in sql server, datatype is datetime,
i have used derived column for date.
In derived column ....
i used (DT_DBDATE)(([FEES-DUE-DT] == "0000-00-00") ? "" : [FEES-DUE-DT])
but whenever execute the package
i got a error msg ...like
[Derived Column [250]] Error: SSIS Error Code DTS_E_INDUCEDTRANSFORMFAILUREONERROR. The "component "Derived Column" (250)" failed because error code 0xC0049064 occurred, and the error row disposition on "output column "Derived Column 1" (270)" specifies failure on error. An error occurred on the specified object of the specified component. There may be error messages posted before this with more information about the failure.
[Derived Column [250]] Error: An error occurred while attempting to perform a type cast.
[SSIS.Pipeline] Error: SSIS Error Code DTS_E_PROCESSINPUTFAILED. The ProcessInput method on component "Derived Column" (250) failed with error code 0xC0209029 while processing input "Derived Column Input" (251). The identified component returned an error from the ProcessInput method. The error is specific to the component, but the error is fatal and will cause the Data Flow task to stop running. There may be error messages posted before this with more information about the failure.
How can i insert 0000-00-00.....or make it black.....????
May 12, 2011 at 10:07 am
You were close. Instead of setting the value to an empty string, try null,
(DT_DBDATE)(([FEES-DUE-DT] == "0000-00-00") ? NULL(DT_WSTR,10) : [FEES-DUE-DT])
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
May 12, 2011 at 4:39 pm
Thanks you so much...
....It's working.,..
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply