Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Not applicable

Count how many times a char is repeated on a string??

Hi

I want to know if there’s a function or a way to count how many times a char is repeated on a string

For example:

“aaa-bbb-ccc-ddd-eee” I want to count the ( - ) how manytimes in this example is 4

Thanks,

1 Solution

Accepted Solutions
Not applicable

Count how many times a char is repeated on a string??

I Found the answerd

substringcount( text , substring)

Returns the number of times the string substring appears within the string text. The result is an integer. If there is no match, 0 is returned

Example:

substringcount ( 'abcdefgcdxyz', 'cd' ) returns 2

3 Replies
Not applicable

Count how many times a char is repeated on a string??

I Found the answerd

substringcount( text , substring)

Returns the number of times the string substring appears within the string text. The result is an integer. If there is no match, 0 is returned

Example:

substringcount ( 'abcdefgcdxyz', 'cd' ) returns 2

stevelord
Valued Contributor

Re: Count how many times a char is repeated on a string??

Thanks, saved me from having to ask or go down the rabbit hole of a manual.   Correct Answer points completely well-earned even when self-awarded.

carbal1952
Contributor II

Re: Count how many times a char is repeated on a string??

The answer is always into a good question.

Community Browser