Back

Addressing SmartConnect Error “Cannot Delete the Integration” Due to Existing TraceHeader Record.

Published: Aug 21, 2026
Post Author Written by Amit Chaudhari

When attempting to delete an integration in SmartConnect On-Premise, you may encounter the following error:



This issue can occur when a large number of trace/log records have accumulated in the TraceHeader and TraceLine tables for the integration.

Causes

SmartConnect maintains execution and trace information in the TraceHeader and TraceLine tables if you enable logging for integration under the Options tab. If these tables contain a significant volume of historical records, SmartConnect may encounter difficulties when attempting to remove the associated trace records during integration deletion.

This can prevent the integration from being deleted successfully.

Solution – Fixing “Cannot Delete the Integration” Error

To resolve the issue, you can manually remove the trace records associated with the integration from the SmartConnect database.

Pre-requisite: Before performing actions, if the trace tables contain a large volume of records, perform the cleanup during non-working hours to minimize the impact on SmartConnect users and integrations.

Step 1: Check the Number of Trace Records

Before deleting anything, check how many records are associated with the integration and run the following queries against the SmartConnect database.

Note: Replace XXXXXXXXX in the queries below with the Map ID / Integration ID of the affected integration.

select count(l.TraceLineId) as [count] from TraceLine l with (nolock) left join TraceHeader h with (nolock) on l.TraceHeaderId = h.TraceHeaderId where  h.MapId = 'XXXXXXXXX'

select count(h.TraceHeaderId) as [count] from TraceHeader as h with (nolock) where h.MapId = 'XXXXXXXXX'

Step 2: Delete the Trace Records

After confirming the record counts and ensuring that it is safe to proceed, run in the same order: likely TraceLine first and TraceHeader next.

Note: Replace XXXXXXXXX in the queries below with the Map ID / Integration ID of the affected integration.

delete l from TraceLine l with (nolock) left join TraceHeader h with (nolock) on l.TraceHeaderId = h.TraceHeaderId where  h.MapId = 'XXXXXXXXX'

delete h from TraceHeader as h with (nolock) where h.MapId = 'XXXXXXXXX'

Verify the Cleanup

After completing the deletion, you can run the count queries from Step 1 again to confirm that the records associated with the integration have been removed.

You can then return to SmartConnect and attempt to delete the integration again.

Note: The SQL statements above are intended specifically for cleaning up trace records associated with the affected integration. Do not remove trace records for other integrations unless you have confirmed that they are safe to delete.

Have a question? Please reach out to us at support@eonesolutions.com.

Feeling stuck? Get the support and guidance you need to help you power through any data challenge

We're on your integration team. Connect with our people and let us know how we can help you.