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

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Srinivas
Creator
Creator

remove prefix values in List Box

Hi,

I have one list box in that remove prefix values with dynamically. see blow example,

20-3214

20-8765

200-3217

2000-8775

30-1365

60-2348

PPSE+10-7654

PPSE+20-8765

in that list box prefix have some times have Two,Three and Four times. This is problem i can't able to remove those prefix values.

Please help on this..

Regards & Thanks

Munna

1 Solution

Accepted Solutions
ashfaq_haseeb
Champion III
Champion III

Hi,

Try below code.

Load *,if(num(Value),Value,subfield(Value, '-' ,2)) as NewValue;

load * inline

[

Value

20-32145

11745

289634

467912

20-8765

200-3217

2000-877587

30-136523

60-2348

PPSE+10-7654997

PPSE+20-876534567

];

Regards

ASHFAQ

View solution in original post

19 Replies
manojkulkarni
Partner - Specialist II
Partner - Specialist II

Didn't get what exactly is ur requirement  ? can elaborate bit.

Didn't understand "list box prefix have some times have Two,Three and Four times" what is this mean

selvakumarsr
Creator
Creator

Then why cant you take only the last 4 characters..

Right(ColumnName,4)

Selva

Srinivas
Creator
Creator
Author

Hi Selva,

i want remove before '-'  Whatever values i have... like 20- ,200-,30-, 2000- so and... this values want to remove.

20-32145

20-8765

200-3217

2000-877587

30-136523

60-2348

PPSE+10-7654997

PPSE+20-876534567



Regards

Munna

Srinivas
Creator
Creator
Author

Hi Manoj,

I want remove before '-'  Whatever values i have... like 20- ,200-,30-, 2000- so and... this values want to remove.

20-32145

20-8765

200-3217

2000-877587

30-136523

60-2348

PPSE+10-7654997

PPSE+20-876534567



Regards

Munna

sujeetsingh
Master III
Master III

Use Subfield () string function

rohit214
Creator III
Creator III

Hi

try this

subfield(Fieldname, '-' ,2)

Thanks

Rohit

selvakumarsr
Creator
Creator

Try this example,

Phone:
NoConcatenate LOAD
ID,
Phone,
Left(Phone, Index(Phone, '-')-1) as Phone1,
Mid(Phone, Index(Phone, '-')+1, 3) as Phone2,
Right(Phone, Len(Phone)-Index(Phone, '-', 2)) as Phone3
Resident PhoneTemp;

Index1.png

sujeetsingh
Master III
Master III

See this sample

manojkulkarni
Partner - Specialist II
Partner - Specialist II

mid(urText,Index(urText,'-')+1)