

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Keepchar() function - can I make that more precise?
Hi,
I have a keepchar() function in a formula I use to calculate a keyfield in one of my tables.
That encompasses two letters, "B" and "M" because some shelfs around here all start with "BM". There is, however, one that I do not want and that also has these two letters in the name - not right next to each other, but the KEEPCHAR() function does not by default recognize that.
=> Is there any way I can use that function (just that one, without combining it with any other (I will try that now)) that I can specify for the KEEPCHAR() function that I want to look for those two letters only if they are right next to each other?
Thanks a lot!
Best regards,
DataNibbler
- Tags:
- qlikview_scripting
Accepted Solutions


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi DataNibbler,
a few from these string-examples would be helpful. But I doubt that there is a way with keep/purge-char functions and you will need other additionally functions like replace or left/right/mid with index or similar.
- Marcus


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi DataNibbler,
a few from these string-examples would be helpful. But I doubt that there is a way with keep/purge-char functions and you will need other additionally functions like replace or left/right/mid with index or similar.
- Marcus


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Marcus,
I thought so. I will have to use INDEX() as that allows me to specify a string, consisting of several letters right next to each other. For now I use a simple LEFT() function in addition to what I had before as I know that those letters are always the very first in the name.
