Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

shubham_kumar
Contributor III

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

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

HI,

    Try this code.

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

Regards,

Kaushik Solanki

shubham_kumar
Contributor III

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

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

MVP
MVP

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

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

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

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

MVP
MVP

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

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
shubham_kumar
Contributor III

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

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

MVP
MVP

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

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

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

Hi,

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

Regards,

Kaushik Solanki

shubham_kumar
Contributor III

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

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