Skip to main content
Announcements
July 15, NEW Customer Portal: Initial launch will improve how you submit Support Cases. IMPORTANT DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
jvargasmayorga
Contributor III
Contributor III

Show total row - some case show null -

Hello Community.

I have this case.

This is a table where you have a value for each record.

jvargasmayorga_0-1639713045697.png

 

I have a table where my dimension (rows) is the "Plaza" field (p1, p2, p3) I have the following calculation where I have to multiply a result by the "value" field according to the selected "square" field. I use this formula:

Sum({$<Cod_Estado_Pasaje = {1,6,7,3,5,4}, [Tipo vehículo] = {'LIGERO'}>} Cantidad_Transito)*value


And as you can see the calculation does it well for each row, but in the TOTAL its no show me the value. I get null.

jvargasmayorga_1-1639713213930.png

 


If I remove the "value" field from the formula, I just leave it like this:

Sum({$<Cod_Estado_Pasaje = {1,6,7,3,5,4}, [Tipo vehículo] = {'LIGERO'}>} Cantidad_Transito)

In this case I get the total value. So the problem seems to be that multiplication with the "value" field, which needs to be done. Any idea how to fix it.

Thank you so much

1 Solution

Accepted Solutions
chrismarlow
Specialist II
Specialist II

Hi,

I think you should either move value inside your Sum (see below right) or use Sum under the Totals Function for the expression (see below middle);

20211217_1.png

Cheers,

Chris.

View solution in original post

4 Replies
chrismarlow
Specialist II
Specialist II

Hi,

I think you should either move value inside your Sum (see below right) or use Sum under the Totals Function for the expression (see below middle);

20211217_1.png

Cheers,

Chris.

Or
MVP
MVP

As suggested by @chrismarlow , you need to move the Value into an aggregation sum. As you have currently written it, this is actually doing:

Sum({$<Cod_Estado_Pasaje = {1,6,7,3,5,4}, [Tipo vehículo] = {'LIGERO'}>} Cantidad_Transito) * Only(value)

Since there is more than one value for the Totals line, Only(value) returns null and the result is null. Therefor, you need Value to be contained within an aggregation function, which in your case, I think should just be inside the regular sum() you already have.

jvargasmayorga
Contributor III
Contributor III
Author

It worked the way it is in the 3rd column.
Thank you so much.

jvargasmayorga
Contributor III
Contributor III
Author

I tried the "only" function, but it still showed me empty.