Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Announcements
Qlik® Product Spotlight: Discover what’s possible. Get more from our products.
See for yourself. Register today.
fasuhaibani
Not applicable

How to Use GetSelectedCount With Defined Dim

Hello everyone!

I was wondering if I can use the function GetSelectedCount with a defined drill down dim. I would like to show the selected year(s) and month(s) on a KPI title.

Thanks!

5 Replies
fkeuroglian
Not applicable

Re: How to Use GetSelectedCount With Defined Dim

Yes you can

try this

if(getcurrentfield( "NAMEOFDRILLDOW" )='','Year',Year,

if(getcurrentfield( "NAMEOFDRILLDOW" )='','Month',Month,Day))

Hope help

Fernando K.

idogridish2
Not applicable

Re: How to Use GetSelectedCount With Defined Dim

Hi,

You can use GetSelectedCount(->My_DrillDown_Dim) to show the selected count of the current dimension,

but if you wont to show the current year or month you need to use somting like  -

Only({$<Year={'$(=Max(Year))'}>}Year)

And

Only({$<[Month Num]={'$(=Max([Month Num]))'}>}Month)

But for the Month you first need to create a month num field

Num(Month(TempDate)) as [Month Num]

Best Regards.

fasuhaibani
Not applicable

Re: How to Use GetSelectedCount With Defined Dim

Thanks Ido!

I tried your expression; however, somehow my defined Dim can't be recognized in the expression!

Any ideas?

Thanks!

idogridish2
Not applicable

Re: How to Use GetSelectedCount With Defined Dim

Hi Feras,

It's showing an error but it's working, try it like I did in the previous post.

if you want you can publish the expression.

idogridish2
Not applicable

Re: How to Use GetSelectedCount With Defined Dim

Hi fasuhaibani ,

Please mark CORRECT/HELPFUL If the answers were satisfying,

if not please keep posting.

Best Regards.