Qlik Community

App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
Qlik Insider: SaaS capabilities for Data Integration and Analytics, May 25th! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
aatish12345
Creator
Creator

Grouping of values from same field

Hello Everyone,

I have a field consisting of below values

Field1:

A

B

C

D

E

Here I want to group only A , B and C together and called it as 'Group1' and want to keep D as it is and the value E should not appear in the final output as shown below:-

New Field:

Group1,

D

Can you please help me achieve this?

 

Aatish

 

 

 

2 Solutions

Accepted Solutions
sasikanth
Master
Master

HI, 

try below one

load *, If(Field1='A' Or Field1='B' Or Field1='C','Group1', if(Field1='D','D')) as New_Field;

load * inline

[

Field1:

A

B

C

D

E

];

 

View solution in original post

anat
Specialist II
Specialist II

Can u try using applymap by creating mapping table

View solution in original post

3 Replies
sasikanth
Master
Master

HI, 

try below one

load *, If(Field1='A' Or Field1='B' Or Field1='C','Group1', if(Field1='D','D')) as New_Field;

load * inline

[

Field1:

A

B

C

D

E

];

 

anat
Specialist II
Specialist II

Can u try using applymap by creating mapping table

aatish12345
Creator
Creator
Author

Hi Sasikant and Anat...

Both the solutions are working as expected...

Thanks 

 

Aatish