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
7345fe65
Commit
7345fe65
authored
Oct 01, 2007
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge mysql.com:/nfsdisk1/lars/bkroot/mysql-4.1-rpl
into mysql.com:/nfsdisk1/lars/MERGE/mysql-4.1-merge
parents
98d1973f
5796be40
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
27 additions
and
2 deletions
+27
-2
libmysqld/ha_blackhole.cc
libmysqld/ha_blackhole.cc
+0
-0
mysql-test/r/delete.result
mysql-test/r/delete.result
+11
-0
mysql-test/t/delete.test
mysql-test/t/delete.test
+13
-0
scripts/mysql_config.sh
scripts/mysql_config.sh
+1
-1
sql/opt_range.cc
sql/opt_range.cc
+2
-1
No files found.
libmysqld/ha_blackhole.cc
deleted
100755 → 0
View file @
98d1973f
mysql-test/r/delete.result
View file @
7345fe65
...
@@ -193,4 +193,15 @@ select @a;
...
@@ -193,4 +193,15 @@ select @a;
@a
@a
1
1
drop table t1;
drop table t1;
CREATE TABLE t1 (
`date` date ,
`time` time ,
`seq` int(10) unsigned NOT NULL auto_increment,
PRIMARY KEY (`seq`),
KEY `seq` (`seq`),
KEY `time` (`time`),
KEY `date` (`date`)
);
DELETE FROM t1 ORDER BY date ASC, time ASC LIMIT 1;
drop table t1;
End of 4.1 tests
End of 4.1 tests
mysql-test/t/delete.test
View file @
7345fe65
...
@@ -184,4 +184,17 @@ delete from t1 where (@a:= f1) order by f1 limit 1;
...
@@ -184,4 +184,17 @@ delete from t1 where (@a:= f1) order by f1 limit 1;
select
@
a
;
select
@
a
;
drop
table
t1
;
drop
table
t1
;
# BUG#30385 "Server crash when deleting with order by and limit"
CREATE
TABLE
t1
(
`date`
date
,
`time`
time
,
`seq`
int
(
10
)
unsigned
NOT
NULL
auto_increment
,
PRIMARY
KEY
(
`seq`
),
KEY
`seq`
(
`seq`
),
KEY
`time`
(
`time`
),
KEY
`date`
(
`date`
)
);
DELETE
FROM
t1
ORDER
BY
date
ASC
,
time
ASC
LIMIT
1
;
drop
table
t1
;
--
echo
End
of
4.1
tests
--
echo
End
of
4.1
tests
scripts/mysql_config.sh
View file @
7345fe65
...
@@ -122,7 +122,7 @@ done
...
@@ -122,7 +122,7 @@ done
cflags
=
`
echo
"
$cflags
"
|sed
-e
's/ *\$//'
`
cflags
=
`
echo
"
$cflags
"
|sed
-e
's/ *\$//'
`
# Same for --libs(_r)
# Same for --libs(_r)
for
remove
in
lmtmalloc static-libcxa i-static
for
remove
in
lmtmalloc static-libcxa i-static
static-intel
do
do
# We know the strings starts with a space
# We know the strings starts with a space
libs
=
`
echo
"
$libs
"
|sed
-e
"s/ -
$remove
*/ /g"
`
libs
=
`
echo
"
$libs
"
|sed
-e
"s/ -
$remove
*/ /g"
`
...
...
sql/opt_range.cc
View file @
7345fe65
...
@@ -825,6 +825,7 @@ uint get_index_for_order(TABLE *table, ORDER *order, ha_rows limit)
...
@@ -825,6 +825,7 @@ uint get_index_for_order(TABLE *table, ORDER *order, ha_rows limit)
if
(
!
(
table
->
keys_in_use_for_query
.
is_set
(
idx
)))
if
(
!
(
table
->
keys_in_use_for_query
.
is_set
(
idx
)))
continue
;
continue
;
KEY_PART_INFO
*
keyinfo
=
table
->
key_info
[
idx
].
key_part
;
KEY_PART_INFO
*
keyinfo
=
table
->
key_info
[
idx
].
key_part
;
uint
n_parts
=
table
->
key_info
[
idx
].
key_parts
;
uint
partno
=
0
;
uint
partno
=
0
;
/*
/*
...
@@ -834,7 +835,7 @@ uint get_index_for_order(TABLE *table, ORDER *order, ha_rows limit)
...
@@ -834,7 +835,7 @@ uint get_index_for_order(TABLE *table, ORDER *order, ha_rows limit)
*/
*/
if
(
!
(
table
->
file
->
index_flags
(
idx
,
0
,
1
)
&
HA_READ_ORDER
))
if
(
!
(
table
->
file
->
index_flags
(
idx
,
0
,
1
)
&
HA_READ_ORDER
))
continue
;
continue
;
for
(
ord
=
order
;
ord
;
ord
=
ord
->
next
,
partno
++
)
for
(
ord
=
order
;
ord
&&
partno
<
n_parts
;
ord
=
ord
->
next
,
partno
++
)
{
{
Item
*
item
=
order
->
item
[
0
];
Item
*
item
=
order
->
item
[
0
];
if
(
!
(
item
->
type
()
==
Item
::
FIELD_ITEM
&&
if
(
!
(
item
->
type
()
==
Item
::
FIELD_ITEM
&&
...
...
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