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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
0f678ee6
Commit
0f678ee6
authored
Oct 17, 2008
by
Georgi Kodinov
Browse files
Options
Browse Files
Download
Plain Diff
merged 5.0-bugteam -> bug 39958
parents
ca6e0576
b5917934
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
35 additions
and
0 deletions
+35
-0
mysql-test/r/order_by.result
mysql-test/r/order_by.result
+16
-0
mysql-test/t/order_by.test
mysql-test/t/order_by.test
+18
-0
sql/sql_select.cc
sql/sql_select.cc
+1
-0
No files found.
mysql-test/r/order_by.result
View file @
0f678ee6
...
@@ -1076,3 +1076,19 @@ set session max_sort_length= 2180;
...
@@ -1076,3 +1076,19 @@ set session max_sort_length= 2180;
select * from t1 order by b;
select * from t1 order by b;
ERROR HY001: Out of sort memory; increase server sort buffer size
ERROR HY001: Out of sort memory; increase server sort buffer size
drop table t1;
drop table t1;
#
# Bug #39844: Query Crash Mysql Server 5.0.67
#
CREATE TABLE t1 (a INT PRIMARY KEY);
CREATE TABLE t2 (a INT PRIMARY KEY, b INT);
CREATE TABLE t3 (c INT);
INSERT INTO t1 (a) VALUES (1), (2);
INSERT INTO t2 (a,b) VALUES (1,2), (2,3);
INSERT INTO t3 (c) VALUES (1), (2);
SELECT
(SELECT t1.a FROM t1, t2 WHERE t1.a = t2.b AND t2.a = t3.c ORDER BY t1.a)
FROM t3;
(SELECT t1.a FROM t1, t2 WHERE t1.a = t2.b AND t2.a = t3.c ORDER BY t1.a)
2
NULL
DROP TABLE t1, t2, t3;
mysql-test/t/order_by.test
View file @
0f678ee6
...
@@ -738,3 +738,21 @@ set session max_sort_length= 2180;
...
@@ -738,3 +738,21 @@ set session max_sort_length= 2180;
select
*
from
t1
order
by
b
;
select
*
from
t1
order
by
b
;
drop
table
t1
;
drop
table
t1
;
--
echo
#
--
echo
# Bug #39844: Query Crash Mysql Server 5.0.67
--
echo
#
CREATE
TABLE
t1
(
a
INT
PRIMARY
KEY
);
CREATE
TABLE
t2
(
a
INT
PRIMARY
KEY
,
b
INT
);
CREATE
TABLE
t3
(
c
INT
);
INSERT
INTO
t1
(
a
)
VALUES
(
1
),
(
2
);
INSERT
INTO
t2
(
a
,
b
)
VALUES
(
1
,
2
),
(
2
,
3
);
INSERT
INTO
t3
(
c
)
VALUES
(
1
),
(
2
);
SELECT
(
SELECT
t1
.
a
FROM
t1
,
t2
WHERE
t1
.
a
=
t2
.
b
AND
t2
.
a
=
t3
.
c
ORDER
BY
t1
.
a
)
FROM
t3
;
DROP
TABLE
t1
,
t2
,
t3
;
sql/sql_select.cc
View file @
0f678ee6
...
@@ -6574,6 +6574,7 @@ only_eq_ref_tables(JOIN *join,ORDER *order,table_map tables)
...
@@ -6574,6 +6574,7 @@ only_eq_ref_tables(JOIN *join,ORDER *order,table_map tables)
{
{
if
(
specialflag
&
SPECIAL_SAFE_MODE
)
if
(
specialflag
&
SPECIAL_SAFE_MODE
)
return
0
;
// skip this optimize /* purecov: inspected */
return
0
;
// skip this optimize /* purecov: inspected */
tables
&=
~
PSEUDO_TABLE_BITS
;
for
(
JOIN_TAB
**
tab
=
join
->
map2table
;
tables
;
tab
++
,
tables
>>=
1
)
for
(
JOIN_TAB
**
tab
=
join
->
map2table
;
tables
;
tab
++
,
tables
>>=
1
)
{
{
if
(
tables
&
1
&&
!
eq_ref_table
(
join
,
order
,
*
tab
))
if
(
tables
&
1
&&
!
eq_ref_table
(
join
,
order
,
*
tab
))
...
...
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