Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
AlexWest
Creator
Creator

Mapping with conditions

Hi everybody!

I have a couple of presets of operations, but there are 8 phone digits that adding in the end of the each preset. And I need to make a Mapping on these presets.

For example, I have:

"USER_ERROR_COMMON# value=02Denied by operator. Phone number11111111;"

"USER_ERROR_COMMON# value=02Denied by operator. Phone number22222222;"

"USER_ERROR_COMMON# value=02Denied by operator. Phone number33333333;"

I need to have: "Denied by operator"

But if I will Map these strings, it will not work because of variable digits in the end.

Is there any solution to make Mapping fucn with such presets?

Labels (3)
3 Replies
Mark_Little
Luminary
Luminary

IF you are trying to just pick out the Denied by operator use the mid function. Then you can do what ever you need from there.

MID(Field, 27,  18)

AlexWest
Creator
Creator
Author

Oh no,

It's just an example. There are hundreds such presets that I want to rename to 8-10 universal names.

marcus_sommer

You may use a mapping with mapsubstring() for such use-case. For example:

m: mapping load * inline [
Lookup, Return
Denied by operator, <<Denied by operator>>
...
];

t: load *, textbetween(mapsubstring('m', StringField), '<<', '>>', 1) as xyz
from abc;

- Marcus