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
CREATE TABLE a(id INT, a1 string, a2 string);
INSERT INTO a VALUES (1,'kind','a1');
INSERT INTO a VALUES (2,'kind','b4');
INSERT INTO a VALUES (1,'family','xx');
INSERT INTO a VALUES (2,'family','yy');
INSERT INTO a VALUES (1,'country','EP');
INSERT INTO a VALUES (2,'country','US');
CREATE TABLE b(b1 string, b2 string);
INSERT INTO b VALUES ('country', 'EP');
SELECT *
FROM a,b
WHERE a.a1 = b.b1
AND a.a2 LIKE b.b2;
ROLLBACK;
It behaves as if the two join conditions where OR-ed, rather than AND-ed.
Notice that both join conditions return the correct result if used alone, only when AND-ed they go wrong.
Reproducible: Always
Steps to Reproduce:
1.run the provided script
2.
3.
Actual Results:
+------+---------+------+---------+------+
| id | a1 | a2 | b1 | b2 |
+======+=========+======+=========+======+
| 1 | country | EP | country | EP |
| 2 | country | US | country | EP |
+------+---------+------+---------+------+
Expected Results:
+------+---------+------+---------+------+
| id | a1 | a2 | b1 | b2 |
+======+=========+======+=========+======+
| 1 | country | EP | country | EP |
+------+---------+------+---------+------+
Date: 2010-11-05 17:48:23 +0100
From: @swingbit
To: SQL devs <>
Version: 2.40.1 (Oct2010) [obsolete]
CC: @njnes
Last updated: 2011-03-28 17:31:23 +0200
Comment 15176
Date: 2010-11-05 17:48:23 +0100
From: @swingbit
User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-GB; rv:1.9.1.12) Gecko/20100907 Fedora/3.5.12-1.fc12 Firefox/3.5.12 GTB7.1
Build Identifier:
The following query returns too many results:
START TRANSACTION;
CREATE TABLE a(id INT, a1 string, a2 string);
INSERT INTO a VALUES (1,'kind','a1');
INSERT INTO a VALUES (2,'kind','b4');
INSERT INTO a VALUES (1,'family','xx');
INSERT INTO a VALUES (2,'family','yy');
INSERT INTO a VALUES (1,'country','EP');
INSERT INTO a VALUES (2,'country','US');
CREATE TABLE b(b1 string, b2 string);
INSERT INTO b VALUES ('country', 'EP');
SELECT *
FROM a,b
WHERE a.a1 = b.b1
AND a.a2 LIKE b.b2;
ROLLBACK;
It behaves as if the two join conditions where OR-ed, rather than AND-ed.
Notice that both join conditions return the correct result if used alone, only when AND-ed they go wrong.
Reproducible: Always
Steps to Reproduce:
1.run the provided script
2.
3.
Actual Results:
+------+---------+------+---------+------+
| id | a1 | a2 | b1 | b2 |
+======+=========+======+=========+======+
| 1 | country | EP | country | EP |
| 2 | country | US | country | EP |
+------+---------+------+---------+------+
Expected Results:
+------+---------+------+---------+------+
| id | a1 | a2 | b1 | b2 |
+======+=========+======+=========+======+
| 1 | country | EP | country | EP |
+------+---------+------+---------+------+
Comment 15185
Date: 2010-11-10 12:55:42 +0100
From: @sjoerdmullender
Changeset 9aee83da8fcf made by Sjoerd Mullender sjoerd@acm.org in the MonetDB repo, refers to this bug.
For complete details, see http//devmonetdborg/hg/MonetDB?cmd=changeset;node=9aee83da8fcf
Changeset description:
Comment 15615
Date: 2011-03-28 17:31:23 +0200
From: @sjoerdmullender
The Mar2011 version has been released.
The text was updated successfully, but these errors were encountered: