Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2012 Forums
 SSIS and Import/Export (2012)
 "Check Constraints" option in Bulkinsert task?

Author  Topic 

learntsql

524 Posts

Posted - 2014-10-29 : 09:34:49
Hi All,

What does "Check Constraints" option in Bulkinsert task in SSIS 2012.

When i uncheck and load the duplicate data should it load or fail it?

can you please explain how it works.

TIA

gbritton
Master Smack Fu Yak Hacker

2780 Posts

Posted - 2014-10-30 : 09:22:13
CHECK_CONSTRAINTS
Specifies that all constraints on the target table or view must be checked during the bulk-import operation. Without the CHECK_CONSTRAINTS hint, any CHECK and FOREIGN KEY constraints are ignored, and after the operation the constraint on the table is marked as not-trusted.

http://msdn.microsoft.com/en-us/library/ms162802.aspx

Whether it loads or fails depends on the table definition and your data. e.g. with CHECK_CONSTRAINTS off, duplicate keys may still be rejected.

Try it with a test table and test data to be sure.
Go to Top of Page
   

- Advertisement -