Skip to main content
Answer

Opportunity ID in Invoice Report – Join does not display value

  • July 1, 2025
  • 7 replies
  • 118 views

Forum|alt.badge.img

Hello everyone,

I'm trying to display the Opportunity ID on the invoice form (Report Designer). To do this, I created the following join structure in the schema:

ARInvoice(NoteID) → CRRelation(RefNoteID)
CRRelation(TargetNoteID) → CROpportunity(NoteID)

Unfortunately, the Opportunity ID still does not appear on the report.

I also tried using SOOrder instead of ARInvoice, but then the line items are shown twice (I’ve tried all possible join options).

Does anyone have a tip on how I should proceed?

Best regards,
Pantea

Best answer by PanteaShahrian

Hi ​@Chris Hackett ,

Yes, I was able to resolve it. I created a custom field on the document where the Opportunity ID can be entered manually, and then I linked that field to the report.

Best regards,
Pantea

7 replies

darylbowman
Captain II
Forum|alt.badge.img+15

Are you creating the Invoices directly from the Opportunities or through Sales Orders?


Forum|alt.badge.img
  • Author
  • Jr Varsity III
  • July 1, 2025

I create the Sales Order from the Opportunities, and the invoice is then generated based on the Sales Order.


darylbowman
Captain II
Forum|alt.badge.img+15

Sorry I don’t have time for a more polished answer, but maybe this will help:

CROpportunity O
INNER JOIN 
    CRRelation R ON O.NoteID = R.TargetNoteID
INNER JOIN 
    SOOrder S ON S.NoteID = R.RefNoteID
INNER JOIN 
    SOOrderShipment SS ON S.OrderType = SS.OrderType AND S.OrderNbr = SS.OrderNbr
INNER JOIN 
    ARTran T ON SS.ShipmentType = T.SOShipmentType AND SS.ShipmentNbr = T.SOShipmentNbr
INNER JOIN 
    ARInvoice I ON T.TranType = I.DocType AND T.RefNbr = I.RefNbr

 


Forum|alt.badge.img
  • Author
  • Jr Varsity III
  • July 1, 2025

thanks


Forum|alt.badge.img
  • Author
  • Jr Varsity III
  • July 2, 2025

@darylbowman 
I tried it, but unfortunately it didn’t work. Do you have any other ideas?
I’m sending you the report—could you please check the relations?

thank you in advance


Chris Hackett
Community Manager
Forum|alt.badge.img
  • Acumatica Community Manager
  • September 24, 2025

Hi ​@PanteaShahrian were you able to find a solution? Thank you!


Forum|alt.badge.img
  • Author
  • Jr Varsity III
  • Answer
  • September 26, 2025

Hi ​@Chris Hackett ,

Yes, I was able to resolve it. I created a custom field on the document where the Opportunity ID can be entered manually, and then I linked that field to the report.

Best regards,
Pantea