You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:38.0) Gecko/20100101 Firefox/38.0
Build Identifier:
This throws a division by zero:
SELECT
count(*) / ((max("end")-min(start)) / 60)
FROM t
GROUP BY s
HAVING max("end")-min(start)<>0 ;
While this does not:
SELECT
count(*) / ((max("end")-min(start)))
FROM t
GROUP BY s
HAVING max("end")-min(start)<>0;
Recreate with:
Reproducible: Always
Steps to Reproduce:
create table t ("end" timestamp, start timestamp, s text);
insert into t ("2015-03-01 00:00:00.135000", "2015-03-01 00:18:00.258000", "foo");
insert into t ("2015-03-01 00:04:00.135000", "2015-03-01 00:22:00.258000", "bar");
SELECT
count(*) / ((max("end")-min(start)) / 60)
FROM t
GROUP BY s
HAVING max("end")-min(start)<>0 ;
Avoid append instructions to disappear
Calling this optimizer after a multiplex expansion
could lead to removal of append() instructions.
The test showing it div_zero.Bug-3742.
The text was updated successfully, but these errors were encountered:
Date: 2015-06-22 02:24:20 +0200
From: Raffy <>
To: SQL devs <>
Version: 11.19.11 (Oct2014-SP3)
CC: @njnes
Last updated: 2017-12-20 22:15:31 +0100
Comment 20935
Date: 2015-06-22 02:24:20 +0200
From: Raffy <>
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:38.0) Gecko/20100101 Firefox/38.0
Build Identifier:
This throws a division by zero:
SELECT
count(*) / ((max("end")-min(start)) / 60)
FROM t
GROUP BY s
HAVING max("end")-min(start)<>0 ;
While this does not:
SELECT
count(*) / ((max("end")-min(start)))
FROM t
GROUP BY s
HAVING max("end")-min(start)<>0;
Recreate with:
Reproducible: Always
Steps to Reproduce:
create table t ("end" timestamp, start timestamp, s text);
insert into t ("2015-03-01 00:00:00.135000", "2015-03-01 00:18:00.258000", "foo");
insert into t ("2015-03-01 00:04:00.135000", "2015-03-01 00:22:00.258000", "bar");
SELECT
count(*) / ((max("end")-min(start)) / 60)
FROM t
GROUP BY s
HAVING max("end")-min(start)<>0 ;
Actual Results:
Division by zero (which it shouldn't!)
Comment 20941
Date: 2015-06-22 21:44:01 +0200
From: @njnes
fixed in jul2015 branch
Comment 21224
Date: 2015-08-28 13:42:57 +0200
From: @sjoerdmullender
Jul2015 has been released.
Comment 26037
Date: 2017-12-20 22:15:31 +0100
From: MonetDB Mercurial Repository <>
Changeset 0276d6b12a9b made by Martin Kersten mk@cwi.nl in the MonetDB repo, refers to this bug.
For complete details, see https//devmonetdborg/hg/MonetDB?cmd=changeset;node=0276d6b12a9b
Changeset description:
The text was updated successfully, but these errors were encountered: