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

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

using variables in a wildcard countif

Hiya Im quite new to qlikview and wondering if anyone can help me

I have a field called leasing co with multiple company codes within it i was looking to count the rows which contain a particular company os for eg how many instances in the column that contain 'vLeasingCo'.

Any help greatly appreciated 🙂

4 Replies
tresesco
MVP
MVP

Use WildMatch() rather than if. Try like:

=Count( WildMatch(YourField, '*' & '$(vLeasingCo)' &'*'), YourField)

Not applicable
Author

Hi tresesco,

It looked perfect but didn't work told me I could only have 1 parameter for a count

simondachstr
Specialist III
Specialist III

count({$<YourField={"*vLeasingCo*"} YourField)

Not applicable
Author

sorry I tried it in the back end and it worked perfectly thanks so much  !