Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
memela
Contributor II
Contributor II

Creating a newfield depending on how the number starts

I have this field called number and i want to create new fields depending on how the number begins .

example, numbers that begins with 12 must be on the same field like Number_12 and Numbers that begins with 17 must be on the same field like Number_17.

Number

122

125

123

172

176

182

134

 

Labels (1)
1 Solution

Accepted Solutions
anat
Master
Master

if(left(Num,2)=17,Num) as Num_17,

if(left(Num,2)=12,Num) as Num_12

View solution in original post

2 Replies
anat
Master
Master

if(left(Num,2)=17,Num) as Num_17,

if(left(Num,2)=12,Num) as Num_12

memela
Contributor II
Contributor II
Author

Thank you Anat!!