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

NullAsValue

Good morning,

I wrote:

ODBC CONNECT TO abc;

NullAsValue *;

Set NullValue = '0 ';


SQL SELECT ......;

But null values ​​remain, how can I do?



Thank you

18 Replies
its_anandrjs

Try with

ODBC CONNECT TO abc;

NullAsValue *;

Set NullValue = '0';

Or

Set NullValue = '';


SQL SELECT ......;


Read the mention documemts

NULL handling in QlikView



its_anandrjs

Or you can use

NullAsValue *;

Set NullValue = '<NULL>';


ODBC CONNECT TO abc;

 

SQL SELECT ......;

alexandros17
Partner - Champion III
Partner - Champion III

The syntax seems correct, are you sure null values come from the table and not from some join ?

Not applicable
Author

Nothing..

All I want to do is setting all the null values at 0..

Not applicable
Author

this is the expression that I have 'NULL'

=-Sum ({} <numero={'5'}> qty) * (pc)

I don't always 'NULL', most of the time it restituice a result.

Not applicable
Author

The problem is in 'pc' because in the table sometimes is 'NULL'.

alexandros17
Partner - Champion III
Partner - Champion III

Ciao Miriana,

are you italian?

When you set null with a value this means that all null values returned from DB became the value you set.

This is not valid for expression, and in your case, I think there are at least 2 errors:

The first is the syntax: Sum ({$<numero={'5'}}> qty) * (pc)

The second is related to pc that is a single value not aggregated in any way (Sum(pc)???)

Let me know

Anonymous
Not applicable
Author

Hi,

You may check specific field instead,

NullAsValue qty, pc;

Set NullValue = '0';

Not applicable
Author

The problem is in 'pc' because sometimes in the table is 'NULL'.

I've already tried to write:

NullAsValue pc;

Set NullValue = '0';

But nothing changed.