Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Independent validation for trusted, AI-ready data integration. See why IDC named Qlik a Leader: Read the Excerpt!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Making a null value into a real value

I'm stuck. How do I turn a null value into something like "Unlabeled" or "Backlog" when I load it from a table in my script?

21 Replies
Not applicable
Author

I was almost certain that this would be the answer but it didn't work either. I tried this-

REPLACE([ITMS Type], ' ', 'Unlabeled'),

Not applicable
Author

Nick,

don't worry, could you export the information (2 rows would be fine) to an .csv? A sample may clarify the issue and give you a proper solution.

girirajsinh
Creator III
Creator III

Try

 

NullAsValue A,B;

 

Set NullValue = 'Unlabeled' ;

 

Load A,B from x.csv;

 

Or

NullAsValue *;

 

Set NullValue = 'Backlog' ;

 

Load A,B from x.csv;

sunny_talwar

Not sure what you mean, can you share a screenshot?

Not applicable
Author

I hope this helps...

Not applicable
Author

Hi Nick,

in the sample data you provided the following snippet gets the result you are mentioning:

  • IF(LEN(TRIM(@1)) = 0, 'Unlabeled', @1) AS APP

That solved the issue?

Not applicable
Author

Still didn't work. Maybe this screenshot will help?

Left Keep

Table5:

Load

[Application ID] as ITMSNumber,

IF(LEN(TRIM([ITMS Type])) = 0, 'Unlabeled', [ITMS Type]) AS [ITMS Type],

[Application Status];

Not applicable
Author

Can I see the snippet in the query you are performing?

Also, can you select the null or empty value and create a text box with the code i provided?

Not applicable
Author

I edited my reply. Please refer to that for the snippet of code.

The box looks like the picture that I attached. Nothing changed.

sunny_talwar

Nick, I know this might not be very straight forward, but can you just run this:

Ord(Len(Trim([ITMS Type])) as Check2

and then make a selection in your ITMS Type field to select the blank option. and then create a list box for Check2 and send us a snapshot of that? This would help us understand what those blanks actually are.