Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: [Q] Porting SQL to Oracle

Re: [Q] Porting SQL to Oracle

From: Billy Verreynne <vslabs_at_onwe.co.za>
Date: Fri, 13 Jun 2003 09:12:01 +0000
Message-ID: <bcbtjt$d57$1@ctb-nnrp2.saix.net>


Niall Litchfield wrote:

> No you aren't, you are saying concatenate an UNKNOWN value to the string
> 'ABC', logically you can't do it.

Well, it is either allowing this:
  'ABC'||NULL
or giving this:
  ORA-99999 Which one do you want? :-)

It's a pain to always do a NVL on every single nullable column in case it does contain a NULL.

> Not only that but it is possible that
> 'ABC'||NULL gives a different result everytime you run it. NULL isn't
> NOTHING.
You're sure? Anything you can throw this way (empty beer cans excluded, full ones permitted if they are Bavarian) to show this?

> If It were I'd be happy to use zero for NULL in numeric/date
> datatypes.

But zero is a value. NULL is not. NULL means "does not exist". It does not even mean an unknown value - that by implication mean that the thing does have a value. NULL means "nothing", not some value hiding somewhere.

Niall, I don't get it. Are you guys disputing that NULL is not a state, but is in fact a value?

Treating NULL as a state (which it is from an OO perpective), Oracle's way of dealing with NULL is not strange at all. It works exactly the same way in the OO code I write.

--
Billy
Received on Fri Jun 13 2003 - 04:12:01 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US