### Title

Portal Field Summary - Average summary glitch

### Post

**Using: FMProADV10.0v3**

Please note the attached image.

- Look at the very last column to the right.
- Now look at the field below the portal on the far right titled 'Avg Mpg'
- Currently the 'Avg MPG' filed is set up as a summary to average the "MPG" portal column.
- However - I need the summary to disregard the last portal row field entry (which is '0') and divide the total by 4 instead of dividing the total by 5.
- Sometimes the last two or three portal rows may have "0's". Thus the calculation has to disregard any rows that have a zero in the last MPG field of the last 1 to 3 portal rows

Can't figure out how to correct the error in calculation. I have experimented with several different calculations but am missing something somewhere.

Any advice will be greatly appreciated.

Thanks, Dekade

On a COPY of your database, try changing the MPG field which I assume this is a calculation field from:

Leg/gallons, to

If (Leg/Gallons <> 0; Leg/Gallons; "") // use the not equal sign instead of <>

This will place "" in the MPG column.

Avg. MPG should be an 'average of' summary field based on the MPG calculation field. This should leave out the field with the zeros.

But there is probably an easier way