AcctSolver
Technical User
I have a report that uses data from two tables containing header data, with a linking table containing detail data used solely to create the relationship between the two header tables. Call one CustomerInvoiceHeader, the second CustomerOrderHeader, and the third LinkOrderInvoice.
I need one line for each customer invoice, which shows the invoice total and customer order#.
The InvoiceHeader table has the Invoice number and invoice total. The CustomerOrderHeader table contains the customer order number. The LinkOrderInvoice table links the invoice on one side, and the order on the other. But the LinkOrderInvoice table has a line for each detail line of the invoice. So, if there are four lines on the invoice, and the total invoice value from the invoice header table is $200, I wind up with $200 four times. I grouped on invoice number, and took a maximum of all the fields, then suppressed the detail. Great. Now I want to be able to get a total of the invoices for each customer in that report. You can't create a subtotal on a maximum. Any idea how I can get that? I tried a running total, but that did not work. I would welcome ideas on another approach - I am SURE this has happened to someone else.
I need one line for each customer invoice, which shows the invoice total and customer order#.
The InvoiceHeader table has the Invoice number and invoice total. The CustomerOrderHeader table contains the customer order number. The LinkOrderInvoice table links the invoice on one side, and the order on the other. But the LinkOrderInvoice table has a line for each detail line of the invoice. So, if there are four lines on the invoice, and the total invoice value from the invoice header table is $200, I wind up with $200 four times. I grouped on invoice number, and took a maximum of all the fields, then suppressed the detail. Great. Now I want to be able to get a total of the invoices for each customer in that report. You can't create a subtotal on a maximum. Any idea how I can get that? I tried a running total, but that did not work. I would welcome ideas on another approach - I am SURE this has happened to someone else.