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
8a310d69
Commit
8a310d69
authored
Aug 26, 2010
by
Alexey Kopytov
Browse files
Options
Browse Files
Download
Plain Diff
Automerge.
parents
947c7f30
6c6a3e8f
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
41 additions
and
1 deletion
+41
-1
mysql-test/r/join.result
mysql-test/r/join.result
+20
-0
mysql-test/t/join.test
mysql-test/t/join.test
+20
-0
sql/sql_select.cc
sql/sql_select.cc
+1
-1
No files found.
mysql-test/r/join.result
View file @
8a310d69
...
...
@@ -1235,4 +1235,24 @@ ORDER BY t1.a, t1.a LIMIT 1) AS d)
1
1
DROP TABLE t1;
#
# Bug #53544: Server hangs during JOIN query in stored procedure called
# twice in a row
#
CREATE TABLE t1(c INT);
INSERT INTO t1 VALUES (1), (2);
PREPARE stmt FROM "SELECT t2.c AS f1 FROM t1 LEFT JOIN
t1 t2 ON t1.c=t2.c RIGHT JOIN
t1 t3 ON t1.c=t3.c
GROUP BY f1;";
EXECUTE stmt;
f1
1
2
EXECUTE stmt;
f1
1
2
DEALLOCATE PREPARE stmt;
DROP TABLE t1;
End of 5.1 tests
mysql-test/t/join.test
View file @
8a310d69
...
...
@@ -897,4 +897,24 @@ GREATEST(t1.a,
DROP
TABLE
t1
;
--
echo
#
--
echo
# Bug #53544: Server hangs during JOIN query in stored procedure called
--
echo
# twice in a row
--
echo
#
CREATE
TABLE
t1
(
c
INT
);
INSERT
INTO
t1
VALUES
(
1
),
(
2
);
PREPARE
stmt
FROM
"SELECT t2.c AS f1 FROM t1 LEFT JOIN
t1 t2 ON t1.c=t2.c RIGHT JOIN
t1 t3 ON t1.c=t3.c
GROUP BY f1;"
;
EXECUTE
stmt
;
EXECUTE
stmt
;
DEALLOCATE
PREPARE
stmt
;
DROP
TABLE
t1
;
--
echo
End
of
5.1
tests
sql/sql_select.cc
View file @
8a310d69
...
...
@@ -8885,10 +8885,10 @@ simplify_joins(JOIN *join, List<TABLE_LIST> *join_list, COND *conds, bool top)
/* Flatten nested joins that can be flattened. */
TABLE_LIST
*
right_neighbor
=
NULL
;
bool
fix_name_res
=
FALSE
;
li
.
rewind
();
while
((
table
=
li
++
))
{
bool
fix_name_res
=
FALSE
;
nested_join
=
table
->
nested_join
;
if
(
nested_join
&&
!
table
->
on_expr
)
{
...
...
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