On Fri, Mar 30, 2001 at 06:49:51PM -0600, will trillich wrote:
> On Fri, Mar 30, 2001 at 12:27:39AM -0500, Gregory Wood wrote:
> > > SELECT sum(grade) / count(grade) As GPA FROM grades;
> > >                     ^^^^ (bad juju if 0)
> > 
> > No kidding... that kid totally failed ALL his classes! And before someone
> > points it out, yes I saw the DBZ.
> 
> 
> dbz?

Division By Zero.  Also, the above would perform integer division, would
need a cast to 'float8' on one of the operands.

-- 
Eric G. Miller <[EMAIL PROTECTED]>

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/users-lounge/docs/faq.html

Reply via email to