QuickSight - Can I use countif + contains?

0

Hi, I'd like to count if a field (string) has a certain text included.

Already tried:

  • countIf({ID}, {Ticket type} contains 'Wochenend')
  • distinct_countIf({ID}, {Ticket type} like '%Wochenend%')
  • distinct_countif({ID}, locate(toLower({Ticket type}), 'Wochenend') <> 0) ...but nothing worked.

Would appreciate help from the community!

Many thanks, Axel

demandé il y a un an468 vues
1 réponse
0
Réponse acceptée

The third option is almost correct but you have used toLower function and yet checked for 'Wochend' with 'W'(caps) instead of 'w' . Here is an example :countIf(ID,locate({Ticket type},'Wochenend')<>0)

AWS
répondu il y a un an

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions