Topic: [SOLVED] Report Grouping Totals with NULL Values
Hello all,
.
I'm out of ideas, and I would appreciate any help with this...
.
I believe the problem might be in my SQL, but I've tried everything that I know of.
.
I get strange results in two different months (July, and September). However, things seem to display fine for August. See the example screenshot.
.
At first I was using:
.
SUM(tl.fuelGallons) as "TotalGallons"
.
So then, I suspected a problem with the null values and switched it to this:
.
case when SUM(tl.fuelGallons) IS NULL then 0 else SUM(tl.fuelGallons) end as "TotalGallons"
.
But FastReport seems to be rounding the values. I have the display format set to %2.3n in both cases.
.
I know derek recommends using the standard reports instead of a SQL report, but I haven't found a way to group the values together. If this is possible, I would prefer it. I tried replicating it without using SQL, but I can't get the same result.