Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Announcements
Announcement: Certain actions are currently causing a Page Not Found error. This is a known issue and we are working with the platform vendor to investigate and resolve it.
Partner
Partner

How to remove values starts with * for a field in qliksense

Hi Experts,

I have the data in below format.

Field0_Pers.areaField1_Name of EE subgroupMonthValue
* PA00 Field2_Mar-18 No14
* PA0X Field2_Mar-18 No13
* PA01 Field2_Mar-18 No39
* PA02 Field2_Mar-18 No159
* PA03 Field2_Mar-18 No41
* PA05 Field2_Mar-18 No0
* PA06 Field2_Mar-18 No32
* PA07 Field2_Mar-18 No29
* PA08 Field2_Mar-18 No38
* PA09 Field2_Mar-18 No209
* PA10 Field2_Mar-18 No52
* PA12 Field2_Mar-18 No14

 

I need to remove all values for the field Field0_Pers.area  which starts with the *.

1 Solution

Accepted Solutions
MVP
MVP

Re: How to remove values starts with * for a field in qliksense

Do you want to remove the "*" prefix from the field value:

PurgeChar(Field0_Pers.area, '*')

Or do you want to exclude the records where there is "*" prefix:

LOAD Field0_Pers.area,
....
From ....
Where Left(Field0_Pers.area, 1) <> '*';

 

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
4 Replies
Highlighted
miskinmaz
Contributor II

Re: How to remove values starts with * for a field in qliksense

Hi,
You can try PurgeChar ( Field0_Pers.area,'*' )
Partner
Partner

Re: How to remove values starts with * for a field in qliksense

Hi Deepaksingh,

Is the field always in this condition? If the answer is yes, use the most simplest version: 

Right(Field0_Pers.area,4)

If your field PAXXX varies in length use:

Right(Field0_Pers.area,Len(Field0_Pers.area)-2))

Otherwise use:

KeepChar(Field0_Pers.area,'abcdefghijklmnopqrstuvwxyz1234567890')

Jordy

Climber

 

Work smarter, not harder
MVP
MVP

Re: How to remove values starts with * for a field in qliksense

Do you want to remove the "*" prefix from the field value:

PurgeChar(Field0_Pers.area, '*')

Or do you want to exclude the records where there is "*" prefix:

LOAD Field0_Pers.area,
....
From ....
Where Left(Field0_Pers.area, 1) <> '*';

 

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Partner
Partner

Re: How to remove values starts with * for a field in qliksense

Thanks  a  lot Jontydkpi.