Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Microsoft Dynamics GP (Archived)

Delete Customer

(0) ShareShare
ReportReport
Posted on by

Hi,

I need to delete a customer from Dynamics GP which have historical transaction related to it and no open/work transactions. The debtor in question have a current balance 0.

I have tried the remove historical transaction process and remove distributions processes but when I try to delete the customer I still get this error:

''Transactions exist for this debtor. The debtor record cannot be deleted''

Can you please guide me what i need to do/check?

Thanks and regards.

*This post is locked for comments

  • Gary_W Profile Picture
    5 on at
    RE: Delete Customer

    Hello. Any chance you have an updated URL to this SQL query? The link isn't working now...

  • Richard Wheeler Profile Picture
    75,848 Moderator on at
    RE: Delete Customer

    Try performing one operation at a time and exit GP between operations. This could be a bug but exiting GP should take care of this.

  • Community Member Profile Picture
    on at
    RE: Delete Customer

    Hi,

    I am trying to use the combiner and modifier of the customer but I am getting the error below:

    Combiner.PNG

    Any ideas why please?

    Regards,

  • Richard Wheeler Profile Picture
    75,848 Moderator on at
    RE: Delete Customer

    Here is David's script to find SQL data.

    blogs.msdn.microsoft.com/.../updated-spsearchonalldb-sql-stored-procedure-to-

    search-an-entire-database/

    Can you create a archive company and leave these records there for auditing purposes and remove them from production? Until those records are removed you will not be able to delete them.

  • Community Member Profile Picture
    on at
    RE: Delete Customer

    Hi Richard,

    Where can I find the search SQL script please?

    I have not deleted records from the table I need the historical data to remain there for audit purposes.

  • Richard Wheeler Profile Picture
    75,848 Moderator on at
    RE: Delete Customer

    Since you said you deleted historical transactions, have you reconciled AR so their summary records go to zero? Perhaps that is what is blocking the deletion. One other thing to try is use Dave Musgrave's SQL search script and search all the tables for the customer IDs of these customers. Then delete all records from all tables. Make sure to perform a backup just to be safe.

  • Community Member Profile Picture
    on at
    RE: Delete Customer

    Hi Kirk,

    So basically here all the customers that I want to delete will be all grouped up under one customer account for example with name Z-Inactive right?

    Will suggest this to the client in question to check if this will suffix.

    Regards,

  • Community Member Profile Picture
    on at
    RE: Delete Customer

    Hi Jeffrey,

    I need to delete these customers since their transaction are way back and they were imported from another system we used before. A new account for some of these customers have been created so I would like to delete these customers.

    There are only few transactions against them for example 5 transactions only. I had processed the checklinks but still the same issues occurred.

    What tables should I look at please?

    Regards,

  • Suggested answer
    KirkLivermont Profile Picture
    5,985 on at
    RE: Delete Customer

    Alexander,

    Jeff's suggestions are all good but I wanted to provide an alternate option.

    In order to maintain the transaction history have you considered using the customer combiner/modifier utility? My suggestion would be to modify the Customer ID to something like Z-Inactive so it appears at the bottom of the list. For future accounts of this nature you could then use the combiner to roll them all into the same record.

    Best regards,

    Kirk

  • Suggested answer
    twelvestrikes Profile Picture
    3,657 on at
    RE: Delete Customer

    Hi Alexander

    Looks like there may be an errant record in one of the tables that is causing the issue.

    My first question is why do you want to delete the record especially since there are transactions posted to this customer?    Why don't you just inactivate the customer so that you maintain the history?

    If you do need to remove the customer, then I would try checklinks and see if it fixes the issue with the errant record.

    Make a backup of the company database first.

    Run checklinks on the following in the sales series:

    Receivables Transaction History Files

    Receivables Open Transactions Files

    Sales History

    Sales Work

    Once checklinks has been completed, try removing the customer record again.

    If this does not solve the issue let me know and we will have to go looking at several tables to see what is going on.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Jainam Kothari – Community Spotlight

We are honored to recognize Jainam Kothari as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > 🔒一 Microsoft Dynamics GP (Archived)

#1
Almas Mahfooz Profile Picture

Almas Mahfooz 3 User Group Leader

Featured topics

Product updates

Dynamics 365 release plans