Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
88d8fccf
Commit
88d8fccf
authored
Oct 12, 2011
by
Sergey Petrunya
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BUG#872702: Crash in add_ref_to_table_cond() when grouping by a PK
- Testcase
parent
ae79dbdb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
0 deletions
+33
-0
mysql-test/r/group_by.result
mysql-test/r/group_by.result
+15
-0
mysql-test/t/group_by.test
mysql-test/t/group_by.test
+18
-0
No files found.
mysql-test/r/group_by.result
View file @
88d8fccf
...
...
@@ -1909,3 +1909,18 @@ a AVG(t1.b) t11c t12c
2 2.0000 7 7
DROP TABLE t1;
# End of 5.1 tests
#
# BUG#872702: Crash in add_ref_to_table_cond() when grouping by a PK
#
CREATE TABLE t1 (a int, PRIMARY KEY (a)) ;
INSERT INTO t1 VALUES (14),(15),(16),(17),(18),(19),(20);
CREATE TABLE t2 (a int) ;
SELECT a
FROM t1
WHERE a = (
SELECT t2.a
FROM t2
) OR t1.a = 73
GROUP BY 1;
a
DROP TABLE t1, t2;
mysql-test/t/group_by.test
View file @
88d8fccf
...
...
@@ -1302,3 +1302,21 @@ DROP TABLE t1;
--
echo
# End of 5.1 tests
--
echo
#
--
echo
# BUG#872702: Crash in add_ref_to_table_cond() when grouping by a PK
--
echo
#
CREATE
TABLE
t1
(
a
int
,
PRIMARY
KEY
(
a
))
;
INSERT
INTO
t1
VALUES
(
14
),(
15
),(
16
),(
17
),(
18
),(
19
),(
20
);
CREATE
TABLE
t2
(
a
int
)
;
SELECT
a
FROM
t1
WHERE
a
=
(
SELECT
t2
.
a
FROM
t2
)
OR
t1
.
a
=
73
GROUP
BY
1
;
DROP
TABLE
t1
,
t2
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment