Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Coming your way, the Qlik Data Revolution Virtual Summit. October 27-29. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Not applicable

picking/removing null values from straight table

Hi,

I have a case in a straight table,  where i need to remove duplicates which have null values in one field.

The straight table is as follows:

Cust_numStatusDateType
A666Aopen13/08/2015
B777Bclosed12/08/2015Exit
B777Bclosed12/08/2015
C888Copen14/08/2015

My requirement is such that, the resultant table should not have duplicates and it should only get the field which do not have 'Type' as NULL

Result should be as follows:

Cust_numStatusDateType
A666Aopen13/08/2015
B777Bclosed12/08/2015Exit
C888Copen14/08/2015

I would like to have some input in achieving this scenario.

8 Replies
Highlighted
Not applicable

You can try with Group by clause:

LOAD

     Cust_Num,

     Status,

     Date,

     Maxstring(Type) AS Type

From table_source

Group by

     Cust_Num,

     Status,

     Date

;

Highlighted
Not applicable

i'm trying to write an expression in the straight table,

in my original table i have duplicate rows, i want to remove the row in which Type = null

Highlighted
Champion
Champion

may be like this?

LOAD distinct

     Cust_Num,

     Status,

     Date,

     Type

From table_source

Highlighted
Master III
Master III

Hi,

Try this as dimension:

=if (not isnull(Type),Cust_Num)

or

=if(len(Type) > 1, Cust_Num)

Thanks,
AS

Highlighted
Champion
Champion

Amit,

If I am not wrong, it will remove all the null values of field

And he want to remove only duplicate value with null...

John, correct me if I am wrong?

Highlighted
Not applicable

yes i wnat to remove ony duplicate values with null

Highlighted
Master III
Master III

Yes buddy you are right , I thought this other way

In this case distinct will work.

Thanks,

AS

Highlighted
Master III
Master III