Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Removing prefix from expression

Hello,

I have a dimension with the following expression:

Arrangement

now how this comes out in the chart is such as this:

023 Hotel services

4122 Flight services

482a Transport services

My question is, how should I edit the expression to remove the numbers, letters and the empty space in front of the arrangement names? All names have a three to four character prefix with numbers, but the fourth character can be a letter. To get a result like this:

Hotel services

Flight services

Transport services

Many Thanks!

1 Solution

Accepted Solutions
Not applicable
Author

Hi,

You can use the next expression:

=mid(Arrangement,findoneof(Arrangement,' ')+1,len(Arrangement)-findoneof(Arrangement,' '))

Succes!

View solution in original post

3 Replies
Anonymous
Not applicable
Author

Try this:

LOAD

  Mid([Arrangement], (Index([Arrangement], ' ', 1) + 1)) as [Arrangement]

  ...

Not applicable
Author

Hi,

You can use the next expression:

=mid(Arrangement,findoneof(Arrangement,' ')+1,len(Arrangement)-findoneof(Arrangement,' '))

Succes!

SunilChauhan
Champion
Champion

use one of below

subfield(yourfieldname,' ',2)  as yournewfieldname in  script or

subfield(yourfieldname,' ',2) in expression

or

subfield(yourfieldname,' ',2) in calculated dimension

Sunil Chauhan