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
57e0bdb3
Commit
57e0bdb3
authored
Aug 19, 2008
by
Michael Widenius
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge
parents
ea31b1e6
edb33da7
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
45 additions
and
12 deletions
+45
-12
mysql-test/r/maria.result
mysql-test/r/maria.result
+21
-4
mysql-test/t/maria.test
mysql-test/t/maria.test
+20
-3
storage/maria/ma_search.c
storage/maria/ma_search.c
+4
-5
No files found.
mysql-test/r/maria.result
View file @
57e0bdb3
...
...
@@ -1900,9 +1900,6 @@ check table t2 extended;
Table Op Msg_type Msg_text
test.t2 check status OK
drop table t2;
drop table if exists t1;
Warnings:
Note 1051 Unknown table 't1'
CREATE TABLE t1 (
col0 float DEFAULT NULL,
col1 date DEFAULT NULL,
...
...
@@ -2080,7 +2077,7 @@ col172 tinyint(1) DEFAULT NULL,
col173 tinytext,
col174 decimal(10,0) DEFAULT NULL,
col175 double DEFAULT NULL
)
engine=maria
DEFAULT CHARSET=latin1 COMMENT='generated'
;
)
engine=maria;
insert ignore into t1 set
col10=abs(28449) % 2,
col11='1973',
...
...
@@ -2205,3 +2202,23 @@ check table t1;
Table Op Msg_type Msg_text
test.t1 check status OK
drop table t1;
create table t1 (a char(200) primary key, b int default 12345) engine=maria;
insert t1 (a) values (repeat('0', 200));
insert t1 (a) values (repeat('1', 200)), (repeat('2', 200)), (repeat('3', 200)),
(repeat('4',
200)), (repeat('5', 200)), (repeat('6', 200)), (repeat('7', 200)),
(repeat('8',
200)), (repeat('9', 200)), (repeat('a', 200)), (repeat('b', 200)),
(repeat('c',
200)), (repeat('d', 200)), (repeat('e', 200)), (repeat('f', 200)),
(repeat('g',
200)), (repeat('h', 200)), (repeat('i', 200)), (repeat('j', 200)),
(repeat('k',
200)), (repeat('l', 200)), (repeat('m', 200)), (repeat('n', 200)),
(repeat('o',
200)), (repeat('p', 200)), (repeat('q', 200)), (repeat('r', 200)),
(repeat('s',
200)), (repeat('t', 200)), (repeat('u', 200)), (repeat('v', 200)),
(repeat('w',
200)), (repeat('x', 200)), (repeat('y', 200)), (repeat('z', 200)),
(repeat('+',
200)), (repeat('-', 200)), (repeat('=', 200)), (repeat('*', 200));
select b from t1 where a >= repeat('f', 200) and a < 'k';
b
12345
12345
12345
12345
12345
drop table t1;
mysql-test/t/maria.test
View file @
57e0bdb3
...
...
@@ -1186,7 +1186,6 @@ insert into t2 values (repeat('x',28)), (repeat('p',21)), (repeat('k',241)),
check
table
t2
extended
;
drop
table
t2
;
drop
table
if
exists
t1
;
CREATE
TABLE
t1
(
col0
float
DEFAULT
NULL
,
col1
date
DEFAULT
NULL
,
...
...
@@ -1364,8 +1363,7 @@ col172 tinyint(1) DEFAULT NULL,
col173
tinytext
,
col174
decimal
(
10
,
0
)
DEFAULT
NULL
,
col175
double
DEFAULT
NULL
)
engine
=
maria
DEFAULT
CHARSET
=
latin1
COMMENT
=
'generated'
;
)
engine
=
maria
;
insert
ignore
into
t1
set
col10
=
abs
(
28449
)
%
2
,
...
...
@@ -1481,6 +1479,25 @@ update ignore t1 set col165=repeat('a',7000);
check
table
t1
;
drop
table
t1
;
#
# Bug#38466 maria: range query returns no data
#
create
table
t1
(
a
char
(
200
)
primary
key
,
b
int
default
12345
)
engine
=
maria
;
insert
t1
(
a
)
values
(
repeat
(
'0'
,
200
));
insert
t1
(
a
)
values
(
repeat
(
'1'
,
200
)),
(
repeat
(
'2'
,
200
)),
(
repeat
(
'3'
,
200
)),
(
repeat
(
'4'
,
200
)),
(
repeat
(
'5'
,
200
)),
(
repeat
(
'6'
,
200
)),
(
repeat
(
'7'
,
200
)),
(
repeat
(
'8'
,
200
)),
(
repeat
(
'9'
,
200
)),
(
repeat
(
'a'
,
200
)),
(
repeat
(
'b'
,
200
)),
(
repeat
(
'c'
,
200
)),
(
repeat
(
'd'
,
200
)),
(
repeat
(
'e'
,
200
)),
(
repeat
(
'f'
,
200
)),
(
repeat
(
'g'
,
200
)),
(
repeat
(
'h'
,
200
)),
(
repeat
(
'i'
,
200
)),
(
repeat
(
'j'
,
200
)),
(
repeat
(
'k'
,
200
)),
(
repeat
(
'l'
,
200
)),
(
repeat
(
'm'
,
200
)),
(
repeat
(
'n'
,
200
)),
(
repeat
(
'o'
,
200
)),
(
repeat
(
'p'
,
200
)),
(
repeat
(
'q'
,
200
)),
(
repeat
(
'r'
,
200
)),
(
repeat
(
's'
,
200
)),
(
repeat
(
't'
,
200
)),
(
repeat
(
'u'
,
200
)),
(
repeat
(
'v'
,
200
)),
(
repeat
(
'w'
,
200
)),
(
repeat
(
'x'
,
200
)),
(
repeat
(
'y'
,
200
)),
(
repeat
(
'z'
,
200
)),
(
repeat
(
'+'
,
200
)),
(
repeat
(
'-'
,
200
)),
(
repeat
(
'='
,
200
)),
(
repeat
(
'*'
,
200
));
select
b
from
t1
where
a
>=
repeat
(
'f'
,
200
)
and
a
<
'k'
;
drop
table
t1
;
--
disable_result_log
--
disable_query_log
eval
set
global
storage_engine
=
$default_engine
,
maria_page_checksum
=
$default_checksum
;
...
...
storage/maria/ma_search.c
View file @
57e0bdb3
...
...
@@ -116,7 +116,8 @@ int _ma_search(register MARIA_HA *info, MARIA_KEY *key, uint32 nextflag,
((
keyinfo
->
flag
&
(
HA_NOSAME
|
HA_NULL_PART
))
!=
HA_NOSAME
||
(
key
->
flag
&
SEARCH_PART_KEY
)
||
info
->
s
->
base
.
born_transactional
))
{
if
((
error
=
_ma_search
(
info
,
key
,
nextflag
,
if
((
error
=
_ma_search
(
info
,
key
,
(
nextflag
|
SEARCH_FIND
)
&
~
(
SEARCH_BIGGER
|
SEARCH_SMALLER
|
SEARCH_LAST
),
_ma_kpos
(
nod_flag
,
keypos
)))
>=
0
||
my_errno
!=
HA_ERR_KEY_NOT_FOUND
)
DBUG_RETURN
(
error
);
...
...
@@ -338,10 +339,8 @@ int _ma_seq_search(const MARIA_KEY *key, uchar *page,
comp_flag
|
tmp_key
.
flag
,
not_used
))
>=
0
)
break
;
#ifdef EXTRA_DEBUG
DBUG_PRINT
(
"loop"
,(
"page: 0x%lx key: '%s' flag: %d"
,
(
long
)
page
,
t_buff
,
flag
));
#endif
DBUG_PRINT
(
"loop_extra"
,(
"page: 0x%lx key: '%s' flag: %d"
,
(
long
)
page
,
t_buff
,
flag
));
memcpy
(
buff
,
t_buff
,
length
);
*
ret_pos
=
page
;
}
...
...
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