Data import issue with SSIS
Hi I am importing data from staging table to the destination table both are in the same database with SSIS. when i run the package it shows some warning regarding the truncation of rows but the package is all green but when i see the destination table there is no data. Actually my source have some difference in data types than the destination. DO you guys think that is the reason but my package should show red i mean fails but its all green. I put the data into that staging table from oracle. So do you guys have any clue???? Thanks in advanceFighttillend_DBA/DEV
April 29th, 2011 2:42pm

Hello SQL_BOSS, What is your max errors setting at?Arthur My Blog
Free Windows Admin Tool Kit Click here and download it now
April 29th, 2011 2:56pm

Green or Red is based on how do you handle the errors and the truncation...maybe it's redircted or ignored. Check the 'Error Output' in the source editor. also it could help if you add a viewer and check the input and the output where it dies.MCITP - BI 2008 http://asqlb.blogspot.com/
April 29th, 2011 2:57pm

Hi, >> This could be happening becasue of truncation of data. For example If your source data 40 character word and destination column data type is char 10 Then the data is truncated. If truncation happens the default setting of the package is to fail. In this case the error output may be configured to redirect the truncated data row to the error output. >> Please add a dataviewer to the pipeline and check if the data is flowing from the source to the destination. >> The package might not be failing because the error output may be configured to redirect the row to error output. Click on error output and check the configuration Please let me know if this was of any help. Keerthi Kiran
Free Windows Admin Tool Kit Click here and download it now
April 29th, 2011 3:04pm

Thanks to all Now as you guys said i changed the error output to fail component and ran the package and got the following error: [OLE DB Destination [22]] Error: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005. An OLE DB record is available. Source: "Microsoft OLE DB Provider for SQL Server" Hresult: 0x80004005 Description: "The statement has been terminated.". An OLE DB record is available. Source: "Microsoft OLE DB Provider for SQL Server" Hresult: 0x80004005 Description: "Cannot insert duplicate key row in object 'dbo.APPOINTMENT' with unique index 'IX_APPOINTMENT_1'.". That IX_APPOINTMENT_1' is the index on four columns and i am putting data into only one column out of those so Now question is how to resolve this thing?????? Fighttillend_DBA/DEV
April 29th, 2011 3:18pm

You'll need to do lookups so you don't insert duplicate rows, also you'll need to handle the nulls if one of the rows doesn't accept nulls. you'll need to use a drived column to fill the other 2 empty columns for that.MCITP - BI 2008 http://asqlb.blogspot.com/
Free Windows Admin Tool Kit Click here and download it now
April 29th, 2011 3:30pm

Jason Would you give me hint about that where to connect which task. I mean the symmetry layout. Thanks Fighttillend_DBA/DEV
April 29th, 2011 3:57pm

Jason Would you give me hint about that where to connect which task. I mean the symmetry layout. Thanks Fighttillend_DBA/DEV Hello, it'll be in the middle of the flow, just after the source. http://www.box.net/shared/n697utqfin and the derived col will be as this example to fill the other remaining columns with any default values. http://www.box.net/shared/dsplg7f9km Please try and post back your experience.
Free Windows Admin Tool Kit Click here and download it now
April 29th, 2011 9:02pm

I guess the data is dirty and you have duplicate records and the constraint in the table is triggering an error in your package. You can use a look up to check if the data is already existing or not and insert on the missing data. Check this link it should be of some help on using look up http://www.sql-server-performance.com/articles/biz/SSIS_New_Features_in_SQL_Server_2008_Part1_p1.aspx If it answered your question please mark the posts as answeredKeerthi Kiran
April 29th, 2011 11:20pm

1) If the package did not fail , the data is good. 2) But to handle this, you could modify the Advanced editor options in the source OLEDB?Please mark my post as an answer if I helped you to resolve the issue or vote up if I helped you.Thanks. Regards and good Wishes, Deepak.
Free Windows Admin Tool Kit Click here and download it now
April 30th, 2011 6:52am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics