Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Please correct the expression

Hi,

I have this expression in my bar chart, but not working as i expect.

Avg({<OFFER_TAT_DIFF-={'-1'}>} OFFER_TAT_DIFF)

That is, I want my chart to show the avg of OFFER_TAT_DIFF avoiding those values where OFFER_TAT_DIFF which is -1.

But even after giving the clause in expression my bar chart comes with -1 values.

Can anyone help me in reframing the expression.

1 Solution

Accepted Solutions
Not applicable
Author

Hi

Try

=Avg({<OFFER_TAT_DIFF ={">=0"}>} OFFER_TAT_DIFF)

Regards

Anders

View solution in original post

6 Replies
Not applicable
Author

hi

try like this.. but am not sure..

=Avg(aggr({<OFFER_TAT_DIFF-={'-1'}>} OFFER_TAT_DIFF))

Regards

A'run'

Not applicable
Author

Hi

I think your expression is right.

Not applicable
Author

Actually the expression was correct.

The problem was that negative values other than -1 also used to come ...

So I actually want to restrict all values that are less than 0.

Can anyone reframe the expression ...am getting an issue with ">" sign as it is already a syntax of expression..

Not applicable
Author

Hi

Try

=Avg({<OFFER_TAT_DIFF ={">=0"}>} OFFER_TAT_DIFF)

Regards

Anders

Not applicable
Author

Hi,

Pls try below one.

Avg({<OFFER_TAT_DIFF-={'<>-1'}>} OFFER_TAT_DIFF)

Hope it will work.

Regards,

Napolean.

Not applicable
Author

Thanks Smile