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: 
Anonymous
Not applicable

How can we exclude '--' from the data.

I want to exclude the -- from the given data. Could any one please help me to do this. Its in table and want to exclude in designer part not thru the scripting part. Is this possible to write an expression in designer part which will exclude the -- from the table.

Best Regards,

Shubham

10 Replies
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

HI,

    Try this code.

     =purgechar( 'Field_Name','--' )

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
Anonymous
Not applicable
Author

Hi Solanki,

I have tried but it doesn't exclude '--' data from the table. It shows and I want this shouldn't come in to the picture or table. the Entire data should come excluding ''--'' part. FYI.. this is also a field value. Its not a null character.

Best

Shubham

jonathandienst
Partner - Champion III
Partner - Champion III

Hi

Are you talking about nulls, or fields that contain '--'?

If you want to elimate nulls, it depends on the data source.For example

LOAD field1,

     field2

FROM data.xls (biff)

Where Len(field2) > 0;

I think the purgechar way will also remove any single hyphens. You could also use

=Replace(Field1, '--', '')

This will not remove single hyphens.

Hope that helps

Jonathan

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

Hi,

    Then as Jonathan suggested you can use the Replace() Function.

     If still it doesnt solve your problem then please upload a sample file.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
jonathandienst
Partner - Champion III
Partner - Champion III

Hi

Do you mean to exclude records with a field containing '--'. Then use

LOAD ....

FROM ....

Where Field1 <> '--';

or

LOAD ...

FROM ...

Where Index(Field1, '--');

If you are loading via SQL SELECT, then the where clause will depend on your database.

Hope that helps

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Anonymous
Not applicable
Author

Hi Jonathan,

Thanks for your reply. But only the thing is I wanted to do all this in designer part without touching the scripting. While loading the data it is possible, I know but I want in designer part. Is this possible.??

Best Regards

Shubham Kumar

jonathandienst
Partner - Champion III
Partner - Champion III

Shubham

Then you need to be specific about the sheet object(s), dimensions and metrics involved.

Regards

Jonathan

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

Hi,

    Have a look at the example. Hope this will help you.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
Anonymous
Not applicable
Author

Hi Satish,

Here I am attaching the problem, actually I want to exclude the '--' which is one kind of field in data (table) if you will have a look on the attachemnt, the circled marked need not to be shown there, it should be excluded.

Best,

Shubham Kumar