Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
cedfoning
Creator
Creator

Changing data in existing table in script

hello, i have an issue.

i have a table with the following data :

Matri ST
3454 E15
7868 E15
98089 E15
5646 E15
9808 E15
345345 E15
789789 E15
78768 E15

 

From the table above, i want to change the values from E15 to E16 for a number of MATRI.

Here is the list of Matri :

 

98089
5646
9808
345345
789789

 

My final table should be something like this :

cedfoning_0-1663602383120.png

Can someone help please ?

 

Thanks

 

@sunny_talwar @vinieme12 

Labels (1)
1 Solution

Accepted Solutions
SerhanKaraer
Creator III
Creator III

Hello Cedfoning,

You could use value mapping as below.

Applymap uses symbol tables, thus replacements will be the fastest for large table with repetitive records.

Exceptions:
mapping
LOAD values, 'E16' as ST INLINE [
values
98089
5646
9808
345345
789789
];

Data:
LOAD Matri, ApplyMap('Exceptions',Matri,ST) as ST INLINE [
Matri ST
3454 E15
7868 E15
98089 E15
5646 E15
9808 E15
345345 E15
789789 E15
78768 E15
] (delimiter is '\t');

View solution in original post

1 Reply
SerhanKaraer
Creator III
Creator III

Hello Cedfoning,

You could use value mapping as below.

Applymap uses symbol tables, thus replacements will be the fastest for large table with repetitive records.

Exceptions:
mapping
LOAD values, 'E16' as ST INLINE [
values
98089
5646
9808
345345
789789
];

Data:
LOAD Matri, ApplyMap('Exceptions',Matri,ST) as ST INLINE [
Matri ST
3454 E15
7868 E15
98089 E15
5646 E15
9808 E15
345345 E15
789789 E15
78768 E15
] (delimiter is '\t');