Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

tomtastic
New Contributor II

Use of Calculated Dimension in Expression

Dear Qlik Community,

I would expect that the below Expression would return 58.072. Instead it takes the entire count of 63.338.

Count( {$<[PO creation time]={'a. same day'}>} [PurchDoc] )

I believe this is the result of the Calculated Dimension [PO creation time] which is used in the Expression.

Is there a way to handle this?

P.S. see attached print screens for more information.

3 Replies
MVP
MVP

Re: Use of Calculated Dimension in Expression

Only physical field names can be used on the LHS of a set expression. So this expression will be ignored giving you the entire count. The simplest workaround is to use an If

=Count(If([PO creation time] = 'a. same day', PurchDoc))

tomtastic
New Contributor II

Re: Use of Calculated Dimension in Expression

Hi Jonathan,

When using your expression an error pops up: Bad field name: [PO creation time].Bad field name.jpg

tomtastic
New Contributor II

Re: Use of Calculated Dimension in Expression

Hi Jonathan,

FYI. I've added a Sample file. This might be useful to play around with the Expression.

Community Browser