Re: Should this query raise an exception?
From: Peter Gulutzan <pgulutzan_at_yahoo.ca>
Date: 17 Aug 2002 09:44:50 -0700
Message-ID: <bc8f8132.0208170844.646c707e_at_posting.google.com>
Date: 17 Aug 2002 09:44:50 -0700
Message-ID: <bc8f8132.0208170844.646c707e_at_posting.google.com>
> "Steve Kass" <skass_at_drew.edu> wrote in message
> news:3D5D361B.C4E72171_at_drew.edu...
> select
> 1/a as R,
> b
> from t
If an expression doesn't need to be evaluated, then it's
implementation-defined whether it shall be evaluated. For
example, in this case, it's up to the vendor to decide
whether to return with divide-by-zero or with the result,
which doesn't depend on that division.
Peter Gulutzan
Co-producer of THE OCELOT SQL DBMS, which returns a result (download
from sourceforge.net/projects/ocelot)
Co-author of SQL-99 Complete, Really
Co-author of SQL Performance Tuning: