Qlik Community

Groupe des Utilisateurs Francophones

Vous êtes francophone? Ce groupe est pour vous. Venez découvrir comment démarrer avec Qlik Sense et QlikView, poser vos questions et partager vos tutos et astuces avec les membres de notre communauté.

Highlighted
Not applicable

Syntax with function Count

Hello everyone.

I would like percentages rather than values. So I tried to use the TOTAL with function Count but it does not work.

Does anyone have an idea?
 

count (DISTINCT{$<date_entree={"<>0"}>} Matricule)

/

count (DISTINCT TOTAL {$<date_entree={"<>0"}>} Matricule)

Thanks in advance,

Emmanuelle

--------------------------------------------------------------------------------------------------------------------------------------

Bonjour tout le monde,

J'aimerais avoir des pourcentages plutôt que des valeurs. Donc j'ai essayé d'utiliser le TOTAL mais cela ne marche pas.

count (DISTINCT{$<date_entree={"<>0"}>} Matricule)

/

count (DISTINCT TOTAL {$<date_entree={"<>0"}>} Matricule)

Quelqu'un aurait-il une idée ?

Emmanuelle

Tags (1)
10 Replies

Re: Syntax with function Count

It seems correct, use ' instead of "

count (DISTINCT{$<date_entree={'<>0'}>} Matricule)

/

count (DISTINCT TOTAL {$<date_entree={'<>0'}>} Matricule)


Let me know

Re: Syntax with function Count

Hi,

try this,

num(

count (DISTINCT{$<date_entree={"<>0"}>} Matricule)

/

count (DISTINCT TOTAL {$<date_entree={"<>0"}>} Matricule) ,'#,##0.00%'

)

Great dreamer's dreams never fulfilled, they are always transcended.
MVP
MVP

Re: Syntax with function Count

Try USING ALL instead of TOTAL...

count (DISTINCT{$<date_entree={'<>0'}>} Matricule)

/

count (DISTINCT ALL {$<date_entree={'<>0'}>} Matricule)


Try with both single and double quotes...

i.e. ' ' and " "

Not applicable

Re: Syntax with function Count

It does not work either...

I think it comes from the function COUNT with DISTINCT and TOTAL. But I do not know how to express it otherwise !

Not applicable

Re: Syntax with function Count

It does not work with the num.

Not applicable

Re: Syntax with function Count

It does not work with the ALL... I tried with the ' and the ", not better.

Re: Syntax with function Count

Hi,

individually did you get  value for your expression,

count (DISTINCT{$<date_entree={"<>0"}>} Matricule)

and

count (DISTINCT TOTAL {$<date_entree={"<>0"}>} Matricule)


Your date_entree field contain date value??


Great dreamer's dreams never fulfilled, they are always transcended.
MVP
MVP

Re: Syntax with function Count

=NUM(COUNT(DISTINCT {<date_entree= {'<>0'}>}Matricule) /COUNT(DISTINCT  {<date_entree= {'<>0'}>} ALL Matricule),'#,##0.00%')

Re: Syntax with function Count

Hi,

try this.

num(

count (DISTINCT{$<date_entree={"<>0"}>} Matricule)

/

count ({$<date_entree={"<>0"}>} Matricule) ,'#,##0.00%'

)

hope it will help you.

Great dreamer's dreams never fulfilled, they are always transcended.