Skip to main content
Question

Two approvals causing details section of SO report to duplicate

  • March 18, 2026
  • 5 replies
  • 61 views

Forum|alt.badge.img

We are displaying the approver on our sales order report.  We bring this information in as follows:

 I have a situation where the same approver is in two approval maps rules (one inside of a workgroup and one as an individual).  So when he approves a document, it comes through twice.

 

This is now causing the detail lines on the sales order print out to duplicate.  I would like to group by the key field here, which is RefNoteID, but I get errors when doing this because it is not a normal numerical ID.

Any suggestions?  There might also be cases where there are two approvers who are not the same person, so grouping on Approver ID is probably not ideal, but maybe a work around for now because I only need to display one approver on the report.  Still wondering if there is a better way though?

5 replies

BenjaminCrisman
Acumatica Employee
Forum|alt.badge.img+4
  • Acumatica Support Team
  • March 24, 2026

@MarciaW In situations where there is a duplicate which can’t be avoided, the best way to fix this is to use a subreport to pull in the duplicating data. I think that in this case though you can probably use the StepID from the approval in your join and it should prevent the duplicates. So if you leave the join on NoteID = RefNoteID and add the unique identifier for StepID (which you can find if you add this to a GI and check the results) then you should only get the approver for this step.


plambert
Semi-Pro III
Forum|alt.badge.img+3
  • Semi-Pro III
  • March 26, 2026

Do you need the workgroup approval line? Perhaps adding an additional condition to the join like Assignee ID = Approved by (ID) can narrow down the scope of the join to just the record you want.


bwhite49
Captain II
Forum|alt.badge.img+12
  • Captain II
  • March 26, 2026

For this table there does not seem to be a good way to get the first or last record in the table, but you can use a creative join to do so.

Gabriel Michaud from Velixo posted a similar join on this community some years back. This join comes in handy in a pinch for these types of situations where you need the first or most recent record.

EPApproval Filter is an Alias for EPApproval, so you are joining the same table onto itself. The below will give you the most recent “approved” approval related to the sales order.

 


BenjaminCrisman
Acumatica Employee
Forum|alt.badge.img+4
  • Acumatica Support Team
  • March 26, 2026

@bwhite49 This type of join where you join a table to itself and then choose a Less Than condition is an easy to get recent records for just about anything 😁


Forum|alt.badge.img
  • Author
  • Semi-Pro II
  • March 30, 2026

Do you need the workgroup approval line? Perhaps adding an additional condition to the join like Assignee ID = Approved by (ID) can narrow down the scope of the join to just the record you want.

Hi Plambert

In this case it was approved by two people, otherwise that would be the perfect solution!