AnsweredAssumed Answered

Sub Summary calculation with IF statement?

Question asked by bnmohr on Feb 4, 2015
Latest reply on Feb 4, 2015 by philmodjunk

Title

Sub Summary calculation with IF statement?

Post

My situation is somewhat like this thread:

http://forums.filemaker.com/posts/709fab0962

 

I am tracking audio signals through sound systems.  If I filter and sort lists of Signals, I can get a report of Devices with the following breakpoints

Device::Location

Device::Name/Model etc

Signals::Inputs

1  Signal Name

2 Signal Name

Outputs

1 Signal Name

2 Signal Name

3 Signal Name

4 Signal Name

Next Device Name/Model...

What I want is for each location, to to summarize the total number of inputs, and the total number of outputs.  I have the summarry field sInput Count that is the count of record ID's which properly sums the inputs but also the outputs for each device, however if I try to total those summaries at the "Input/Output" breakpoint, it's summing all of them together (both inputs and outputs)- what I want is a sum IF Input Output Flag="Input" and another sum IF = "Output"

Ideas?

My current solution is to convert the Input Output Flag text field into two number fields cIsInput and cIsOutput which is just the evaluation ="Input" or ="Output" and then total those fields at the end.  It works, I was just hoping there was a more elegant way to do this based on the sub summary lines.  In hind sight I should have defined the input/output flag as a number field knowing it would eventually end up in a calculation.

Thanks

Outcomes