Codepoet42
Programmer
This should be really easy, but for some reason I can't figure it out. I have a report in Crystal XI that has a Sum field in the group footer. This field is the sum of the LineItemHistory.LineCost (number) value in the details section.
The sum is great at showing the sum of the LineCost values for all line items in the details section, but here's the problem: The LineCost value is in a record (LineItemHistory) that also has a boolean "Include" field, and I only need to show the sum of the line items that are included (ie Include = 1).
I can suppress the details section so only records with "{LineItemHistory.Include} = True" display. However, I can't figure out how to add a condition to the Sum field so it only totals the values of LineItemHistory records with a 1 (true) for the Include field.
I tried using a formula field (@SumLineCost) in the group footer to conditionally set "Formula = Sum({LineItemHistory.LineCost})" only when LineItemHistory.Include is true, but it keeps coming up with the total of all line items, not just the included ones.
Can anyone help me? The report draws all its data from tables in our MSDE 2000 SQL database. There are no .ttx files or stored procedures involved.
Thanks in advance...
The sum is great at showing the sum of the LineCost values for all line items in the details section, but here's the problem: The LineCost value is in a record (LineItemHistory) that also has a boolean "Include" field, and I only need to show the sum of the line items that are included (ie Include = 1).
I can suppress the details section so only records with "{LineItemHistory.Include} = True" display. However, I can't figure out how to add a condition to the Sum field so it only totals the values of LineItemHistory records with a 1 (true) for the Include field.
I tried using a formula field (@SumLineCost) in the group footer to conditionally set "Formula = Sum({LineItemHistory.LineCost})" only when LineItemHistory.Include is true, but it keeps coming up with the total of all line items, not just the included ones.
Can anyone help me? The report draws all its data from tables in our MSDE 2000 SQL database. There are no .ttx files or stored procedures involved.
Thanks in advance...