Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
doespirito
Creator
Creator

wrong results on a straight table

Hello,

Could every-body help me to know (see attached file) whitch mistake i make in this straight table.

One élément of a dimension desappears in the average amount.

thank you very much.

Best regards,

Arnault Capture03042017.PNG

1 Solution

Accepted Solutions
sunny_talwar

May be this:

round((Sum({$<MOIS={"<=$(=max(MOIS))"},[CANALCOM]={'OUI'}>} (VENTEOJD)) / max(TOTAL MOIS)))

View solution in original post

7 Replies
aarkay29
Specialist
Specialist

PFA

Just use the expression total instead of sum of rows.

doespirito
Creator
Creator
Author

ok thank you,

but one element (37261 whitch is 192 in november) , has desappeared in the straight table.

do you know why ?

sunny_talwar

May be this:

round((Sum({$<MOIS={"<=$(=max(MOIS))"},[CANALCOM]={'OUI'}>} (VENTEOJD)) / max(TOTAL MOIS)))

doespirito
Creator
Creator
Author

yes it is perfect.

just a question : why do i have to add TOTAL here ?

thank you very much

aarkay29
Specialist
Specialist

your expression max(MOIS) returns null for the ID 37261 since it has value in the mois of 11 therefore the 37261 returns'-' and automatically suppressed

you need to to use max(total MOIS) to return 12 or if you want to return 11 which is max(mois) for value 37261 use this exp Max({$<MOIS={"<=$(=max(MOIS))"},[CANALCOM]={'OUI'}>}MOIS)

since you need avg for 12 months max(total MOIS) will be your expression

Hope it helps

sunny_talwar

Max(MOIS) for 37261 was somehow showing as null... changed it to Max(TOTAL MOIS) which calculate Max MOIS across all the INSEE

doespirito
Creator
Creator
Author

Aar, Sunny,

Your answers are very clear.


Thank you very much.


Arnault