Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
ioannagr
Creator III
Creator III

set nulls to temporal values in data manager

Hello all.

 

I have a date field which is recognized correctly by qlik sense  as a temporal value field.

The thing is I want to manage some test data from my dataset e.g. some future dates and data manager won't let me do this. There isn't even an option as "set nulls" or "replace".

 

I tried treating it as a dimension but i don't think this is best practice.

 

Any ideas?

1 Solution

Accepted Solutions
treysmithdev
Partner Ambassador
Partner Ambassador

I would try using this:

If(Match(Text(datefield),'3/3/2062', '01/01/1113','05/05/1113') > 0, Null(), datefield) as datefield

 

Blog: WhereClause   Twitter: @treysmithdev

View solution in original post

4 Replies
treysmithdev
Partner Ambassador
Partner Ambassador

I don't think there is currently a way to do it in the data manager unless you make a calculated field. 

Something like: 

If(Len([FieldName]) = 0, 'NULL VALUE',[FieldName]) as [FieldName]

 

Doing it in the script editor allows some more flexibility using NullAsValue.

Blog: WhereClause   Twitter: @treysmithdev
ioannagr
Creator III
Creator III
Author

Hello and thank you for the response.

I don't have blank field values, but some odd dates I want to set as null.

For example, 2062, 1113, that  are test data. Could I do:

 

If ( {<datefield={'3/3/2062', '01/01/1113','05/05/1113'}>}, 'null',datefield) as datefield ?

 

treysmithdev
Partner Ambassador
Partner Ambassador

I would try using this:

If(Match(Text(datefield),'3/3/2062', '01/01/1113','05/05/1113') > 0, Null(), datefield) as datefield

 

Blog: WhereClause   Twitter: @treysmithdev
ioannagr
Creator III
Creator III
Author

Thanks! This worked. 😄