The INGOUR_CONSTRAINT table hint in SQL server is used in conjunction with bulk insert statement. It Instructs SQL Server to disable check and foreign key constraint during the bulk insert operation or update or delete.
This is useful when we need to
load data might violate constraint and we are plan to address the constraint
violation later.
This hint does not disable the
Primary key or unique key constraint. It only effects the check and foreign key
constraint. It disables constraints temporarily.
This Hint is used in BCP.
This hint will bypass the foreign
key and check constraint and allowing the data to be inserted. Disabling the
constraint can lead to data integrity issue. So be careful when we are using
this hint. Asway we need to re-enable constraints after our operation and
consider validating data integrity after bypass constraints.
No comments:
Post a Comment
If you have any doubt, please let me know.