SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
Query/Representation of Null in Oracle

 
Reply to topic    SoftTree Technologies Forum Index » DB Audit, DB Mail, DB Tools View previous topic
View next topic
Query/Representation of Null in Oracle
Author Message
Karthik



Joined: 14 Aug 2005
Posts: 1

Post Query/Representation of Null in Oracle Reply with quote

I would be glad if I can know the internal representation of Null values and the select query to see the represented value of null

Sun Aug 14, 2005 7:10 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 6505

Post Re: Query/Representation of Null in Oracle Reply with quote

The internal representation is true null (e.g null value), not a string substitute for it like [null] or something else.
So when you are seeing no value in a data grid or report cell you are really seeng NULL value.

PS. Note: In Oracle empty strings and NULLs are the same.
To check for a null value you can alsways use something like

SELECT nvl(col_name, 'Look here is a NULL'),

nvl(col_name2, 'Look here is a NULL too')
FROM my_table

: I would be glad if I can know the internal representation of Null values and
: the select query to see the represented value of null

Sun Aug 14, 2005 7:45 am View user's profile Send private message
Prasad Patnaik



Joined: 15 Aug 2005
Posts: 1

Post Re: Query/Representation of Null in Oracle Reply with quote

I do understand that Empty String is represented as
Null. But We want to know what binary value the Null
which stored Null field in Oracle Database.

Can we print the Binary value at SQL*Plus using any
SQL query.

It is known that ASCII 0 is Null.
Is this value is stored in Null Field in the Oracle Database.

Mon Aug 15, 2005 3:18 am View user's profile Send private message
DickV



Joined: 15 Aug 2005
Posts: 1

Post Re: Query/Representation of Null in Oracle Reply with quote

: I do understand that Empty String is represented as
: Null. But We want to know what binary value the Null
: which stored Null field in Oracle Database.

: Can we print the Binary value at SQL*Plus using any
: SQL query.

: It is known that ASCII 0 is Null.
: Is this value is stored in Null Field in the Oracle Database.

Just by accident came accross this question
From Oracle Concept Manuel (see otn.oracle.com)
"A null is the absence of a value in a column of a row...
Most comparisons between nulls and other values are by definition neither true nor false, but unknown. To identify nulls in SQL, use the IS NULL predicate. Use the SQL function NVL to convert nulls to non-null values.
"
So the Null has NO value, it is an empty string.
Hope this helps.

Mon Aug 15, 2005 7:15 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 6505

Post Re: Query/Representation of Null in Oracle Reply with quote

: Just by accident came accross this question
: From Oracle Concept Manuel (see otn.oracle.com)
: "A null is the absence of a value in a column of a row...
: Most comparisons between nulls and other values are by definition neither
: true nor false, but unknown. To identify nulls in SQL, use the IS NULL
: predicate. Use the SQL function NVL to convert nulls to non-null values.
: "
: So the Null has NO value, it is an empty string.
: Hope this helps.

Mon Aug 15, 2005 9:21 am View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » DB Audit, DB Mail, DB Tools All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.