web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested Answer

Emailing Invoice's Error

(0) ShareShare
ReportReport
Posted on by 14
Hello!
 
I have a user that emails invoices regularly and started receiving the below error this week. There have been no updates or changes in the last few months. The problem with this is that its sending two emails to the customer instead of one. When I look at this table in the SQL side, I don't see the SOPNUMBE that is mentioned in the error. I currently having check links running on the sales tables, we will see if that comes up with anything but, not sure what to do to fix if not.
 
GP version: 18.5.1635
 
 
When clicking More Info:
 
 
Categories:
I have the same question (0)
  • Community member Profile Picture
    14 on at
    Emailing Invoice's Error
    Update - check links for all Sales category items didn't appear to change anything with this process. The error still comes up.
  • Kaja Mohiadeen Profile Picture
    244 on at
    Emailing Invoice's Error
    Hi,
     
    Take SQL Backup of Company and Dynamics Database.  From GP>>Maintenance >> SQL. 
    Select the Company Database, and select "Sales Document Header Temp" and then select Drop Table and Create Table and run process.
     
    I hope this will resolve this issue. (SQL Table: SOP50200)
  • Judy Profile Picture
    Microsoft Employee on at
    Emailing Invoice's Error
    Hi,
     
    Can you manually investigate the data in the table to identify any duplicate records or conflicting keys in SQL side.
    You can refer to the Microsoft Document for the steps about the duplicate records:
     
    Best Regards,
    Judy
  • Suggested answer
    Lisa at AonC.com Profile Picture
    912 Super User 2025 Season 2 on at
    Emailing Invoice's Error
    Is another user able to email the same document without an issue?

    Since you are familiar with SQL, check the related SOP tables (either work or history depending on what is being emailed) to see if there are any funky records (perhaps an abandoned void, a blank Customer Number, etc.) that may require some cleanup.

    [Tables numbered in the 50000s are generally temporary tables so you may not see data in the table once the process has ended.]
  • Suggested answer
    Beat Bucher  GP Geek  GPUG All Star Profile Picture
    28,058 Moderator on at
    Emailing Invoice's Error
    This can be a tricky one to figure out...
     
    As Lisa suggested, this refers to some SOP temp table that is used during the process of e-mailing sales documents out, but the problem could actually be in your SOP10xxx tables which holds the OPEN / WORK data of your Sales Transaction. 
     
    You should try to run a full search across all tables (google it, there are some SQL scripts out there to locate any string from any table in a DB) to locate the value for INV071303. then have a peek in all the records returned. You may discover that some rows are duplicated and thus causing the PK violation. 
     
    HTH,
    Beat 

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 683 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 563 Super User 2025 Season 2

#3
Sohaib Cheema Profile Picture

Sohaib Cheema 398 User Group Leader

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans