Using NULL values in calculated results - Mailing list pgsql-general

From Zak McGregor
Subject Using NULL values in calculated results
Date
Msg-id 200102231134.NAA00999@zak.home.dom
Whole thread Raw
Responses Re: Using NULL values in calculated results  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
Hi all

Am I wrong in thinking that any mathematical operation with a null value
should result in a null result? The reason I ask is that the following all
behave as expected:
select 1+null => null
select 1*null => null

but select 1/null => division by zero error. Is this how it is supposed to
work? I've tried on 7.0.2 and 7.0.3.


Thanks

Cheers

Zak

pgsql-general by date:

Previous
From: Karel Zak
Date:
Subject: Re: International support
Next
From: Pete Forman
Date:
Subject: Re: Questions to lists / translations