0
Fixed

Container Foreign Key conflict on delete connector

Tony Sheehy 12 years ago updated by anonymous 8 years ago 4

On deleting a connector that has been used for FIM Exports and CSV full-imports, the following exception was thrown:

System.ServiceModel.FaultException`1[System.ServiceModel.ExceptionDetail]: The ALTER TABLE statement conflicted with the FOREIGN KEY constraint "FK_Container_Container". The conflict occurred in database "Unify.IdentityBroker", table "dbo.Partition", column 'PartitionId'. (Fault Detail is equal to An ExceptionDetail, likely created by IncludeExceptionDetailInFaults=true, whose value is: System.Data.SqlClient.SqlException: The ALTER TABLE statement conflicted with the FOREIGN KEY constraint "FK_Container_Container". The conflict occurred in database "Unify.IdentityBroker", table "dbo.Partition", column 'PartitionId'. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning()
at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async)
at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
at System...).

Tony, do you have the rest of the stack trace?

Assigning fix version

This was due to Container not being cleared on Clear Data.sql; this has been updated and can be closed on the regression test.

This has been confirmed in the latest installation on prdgrp-test3, with a container injected into the DB, and a lone connector being deleted, forcing the clear script to be called.