<rss version="2.0" xmlns:a10="http://www.w3.org/2005/Atom"><channel><title>Inflectra Customer Forums: Can't delete a project (Thread)</title><description>Trying to delete a project from a partial/failed import from HP QC 10.        When I try the delete, ST says it can't. Application log shows:     APPLICATION.Business.DataAccess::ExecuteNonQuery: The DELETE statement conflicted with the REFERENCE constraint "FK_TST_PROJECT_TST_ARTIFACT_ATTACHMENT". The conflict occurred in database "SpiraTest", table "dbo.TST_ARTIFACT_ATTACHMENT", column 'PROJECT_ID'. The statement has been terminated. [System.Data.SqlClient.SqlException] Stack Trace: at System.Data.SqlClient.SqlConnection.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.Data.SqlClient.SqlCommand.ExecuteNonQuery() at APPLICATION.Business.DataAccess.ExecuteNonQuery(String sqlCommand, Boolean useParam) </description><language>en-US</language><copyright>(C) Copyright 2006-2026 Inflectra Corporation.</copyright><managingEditor>support@inflectra.com</managingEditor><category domain="http://www.dmoz.org">/Computers/Software/Project_Management/</category><category domain="http://www.dmoz.org">/Computers/Software/Quality_Assurance/</category><generator>KronoDesk</generator><a10:contributor><a10:email>support@inflectra.com</a10:email></a10:contributor><a10:id>http://www.inflectra.com/kronodesk/forums/threads</a10:id><ttl>120</ttl><link>/Support/Forum/spiratest/issues-questions/276.aspx</link><item><guid isPermaLink="false">threadId=276</guid><author>Matt Warren (mwarren@hnw.com)</author><title>Can't delete a project</title><description>Trying to delete a project from a partial/failed import from HP QC 10.        When I try the delete, ST says it can't. Application log shows:     APPLICATION.Business.DataAccess::ExecuteNonQuery: The DELETE statement conflicted with the REFERENCE constraint "FK_TST_PROJECT_TST_ARTIFACT_ATTACHMENT". The conflict occurred in database "SpiraTest", table "dbo.TST_ARTIFACT_ATTACHMENT", column 'PROJECT_ID'. The statement has been terminated. [System.Data.SqlClient.SqlException] Stack Trace: at System.Data.SqlClient.SqlConnection.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.Data.SqlClient.SqlCommand.ExecuteNonQuery() at APPLICATION.Business.DataAccess.ExecuteNonQuery(String sqlCommand, Boolean useParam) </description><pubDate>Wed, 02 May 2012 03:17:46 -0400</pubDate><a10:updated>2012-07-27T19:08:26-04:00</a10:updated><link>/Support/Forum/spiratest/issues-questions/276.aspx</link></item><item><guid isPermaLink="false">messageId=535</guid><author>David J (adam.sandman+support@inflectra.com)</author><title> To give specific support on this issue, please contact Inflectra support. It looks like an attachme</title><description> To give specific support on this issue, please contact Inflectra support. It looks like an attachment that has gotten cross-linked across a project. There is a SQL command that should fix it:    DELETE FROM TST_ARTIFACT_ATTACHMENT WHERE PROJECT_ID = X    (where X is the ID of the project in SpiraTest) </description><pubDate>Thu, 24 May 2012 09:39:15 -0400</pubDate><a10:updated>2012-05-24T09:39:15-04:00</a10:updated><link>/Support/Forum/spiratest/issues-questions/276.aspx#reply535</link></item><item><guid isPermaLink="false">messageId=612</guid><author>Christoph Bruendler (christoph.bruendler@frama.com)</author><title>There is still a project I can't delete... Here is what we found in Application log:  we got several</title><description>There is still a project I can't delete... Here is what we found in Application log:  we got several entries here just the first one (as pasting two much, fills up the capacity of the text field):   Error 1  &#xD;
   APPLICATION.Business.DataAccess::ExecuteNonQuery:  &#xD;
  The DELETE statement conflicted with the REFERENCE constraint &#xD;
"FK_TST_PROJECT_ATTACHMENT_TYPE_TST_PROJECT_ATTACHMENT". The conflict occurred &#xD;
in database "SpiraTeam", table "dbo.TST_PROJECT_ATTACHMENT", column &#xD;
'PROJECT_ATTACHMENT_TYPE_ID'.  &#xD;
  The statement has been terminated. &#xD;
[System.Data.SqlClient.SqlException]  &#xD;
&#xD;
  Stack Trace:  &#xD;
&#xD;
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean &#xD;
breakConnection)  &#xD;
&#xD;
at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, &#xD;
Boolean breakConnection)  &#xD;
&#xD;
at &#xD;
System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning()  &#xD;
&#xD;
at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand &#xD;
cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, &#xD;
TdsParserStateObject stateObj)  &#xD;
&#xD;
at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, &#xD;
Boolean async)  &#xD;
&#xD;
at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult &#xD;
result, String methodName, Boolean sendToPipe)  &#xD;
&#xD;
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()  &#xD;
&#xD;
at APPLICATION.Business.DataAccess.ExecuteNonQuery(String sqlCommand, Boolean &#xD;
useParam)  &#xD;
&#xD;
  Error 2  &#xD;
   APPLICATION.Business.Attachment::DeleteAllProjectAttachmentInfo: Database foreign key violation occurred &#xD;
[APPLICATION.Business.DataAccessForeignKeyException]  etc....  I have delete the only incident in that project, and the table dbo.TST_ARTIFACT_ATTACHMENT" does not contain any record for this project anymore.  What shall we try next? &#xD;
&#xD;
</description><pubDate>Wed, 25 Jul 2012 14:06:45 -0400</pubDate><a10:updated>2012-07-25T14:06:45-04:00</a10:updated><link>/Support/Forum/spiratest/issues-questions/276.aspx#reply612</link></item><item><guid isPermaLink="false">messageId=617</guid><author>David J (adam.sandman+support@inflectra.com)</author><title>&#xD;
&#xD;
&#xD;
It looks like you have some project attachment types that have somehow gotten linked to attach</title><description>&#xD;
&#xD;
&#xD;
It looks like you have some project attachment types that have somehow gotten linked to attachments in a different project. You need to get a list of all the PROJECT_ATTACHMENT_TYPE_IDs in the project you're deleting and make sure that all attachments (TST_PROJECT_ATTACHMENT) in other projects are not using them.</description><pubDate>Fri, 27 Jul 2012 19:08:26 -0400</pubDate><a10:updated>2012-07-27T19:08:26-04:00</a10:updated><link>/Support/Forum/spiratest/issues-questions/276.aspx#reply617</link></item></channel></rss>