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
829772b4
Commit
829772b4
authored
Jun 19, 2006
by
serg@serg.mylan
Browse files
Options
Browse Files
Download
Plain Diff
Merge bk-internal.mysql.com:/home/bk/mysql-5.1
into serg.mylan:/usr/home/serg/Abk/mysql-5.1
parents
65543294
23a4a859
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
57 additions
and
24 deletions
+57
-24
include/my_global.h
include/my_global.h
+3
-0
mysql-test/r/fulltext2.result
mysql-test/r/fulltext2.result
+8
-0
mysql-test/t/fulltext2.test
mysql-test/t/fulltext2.test
+10
-0
sql/ha_ndbcluster.cc
sql/ha_ndbcluster.cc
+3
-3
sql/mysqld.cc
sql/mysqld.cc
+4
-3
sql/sql_show.cc
sql/sql_show.cc
+4
-1
storage/myisam/ft_parser.c
storage/myisam/ft_parser.c
+22
-10
storage/myisam/ft_update.c
storage/myisam/ft_update.c
+0
-5
storage/myisam/ftdefs.h
storage/myisam/ftdefs.h
+3
-2
No files found.
include/my_global.h
View file @
829772b4
...
...
@@ -797,6 +797,9 @@ typedef SOCKET_SIZE_TYPE size_socket;
#define DBL_MAX 1.79769313486231470e+308
#define FLT_MAX ((float)3.40282346638528860e+38)
#endif
#ifndef SSIZE_MAX
#define SSIZE_MAX ((~((size_t) 0)) / 2)
#endif
#if !defined(HAVE_ISINF) && !defined(isinf)
#define isinf(X) 0
...
...
mysql-test/r/fulltext2.result
View file @
829772b4
...
...
@@ -241,3 +241,11 @@ select * from t1 where match a against('ab c' in boolean mode);
a
drop table t1;
set names latin1;
SET NAMES utf8;
CREATE TABLE t1(a VARCHAR(255), FULLTEXT(a)) ENGINE=MyISAM DEFAULT CHARSET=utf8;
INSERT INTO t1 VALUES('„MySQL“');
SELECT a FROM t1 WHERE MATCH a AGAINST('“MySQL„' IN BOOLEAN MODE);
a
„MySQL“
DROP TABLE t1;
SET NAMES latin1;
mysql-test/t/fulltext2.test
View file @
829772b4
...
...
@@ -221,3 +221,13 @@ drop table t1;
set
names
latin1
;
# End of 4.1 tests
#
# BUG#19580 - FULLTEXT search produces wrong results on UTF-8 columns
#
SET
NAMES
utf8
;
CREATE
TABLE
t1
(
a
VARCHAR
(
255
),
FULLTEXT
(
a
))
ENGINE
=
MyISAM
DEFAULT
CHARSET
=
utf8
;
INSERT
INTO
t1
VALUES
(
'„MySQL“'
);
SELECT
a
FROM
t1
WHERE
MATCH
a
AGAINST
(
'“MySQL„'
IN
BOOLEAN
MODE
);
DROP
TABLE
t1
;
SET
NAMES
latin1
;
sql/ha_ndbcluster.cc
View file @
829772b4
...
...
@@ -10364,7 +10364,7 @@ static int ndbcluster_fill_files_table(THD *thd, TABLE_LIST *tables,
table
->
field
[
c
++
]
->
set_null
();
// DELETED_ROWS
table
->
field
[
c
++
]
->
set_null
();
// UPDATE_COUNT
table
->
field
[
c
++
]
->
store
(
lfg
.
getUndoFreeWords
());
// FREE_EXTENTS
table
->
field
[
c
++
]
->
store
(
lfg
.
getUndoBufferSize
()
);
// TOTAL_EXTENTS
table
->
field
[
c
++
]
->
store
(
uf
.
getSize
()
/
4
);
// TOTAL_EXTENTS
table
->
field
[
c
++
]
->
store
(
4
);
// EXTENT_SIZE
table
->
field
[
c
++
]
->
store
(
uf
.
getSize
());
// INITIAL_SIZE
...
...
@@ -10394,8 +10394,8 @@ static int ndbcluster_fill_files_table(THD *thd, TABLE_LIST *tables,
table
->
field
[
c
++
]
->
store
(
"NORMAL"
,
6
,
system_charset_info
);
char
extra
[
3
0
];
int
len
=
my_snprintf
(
extra
,
sizeof
(
extra
),
"CLUSTER_NODE=%u
"
,
id
);
char
extra
[
10
0
];
int
len
=
my_snprintf
(
extra
,
sizeof
(
extra
),
"CLUSTER_NODE=%u
;UNDO_BUFFER_SIZE=%lu"
,
id
,
lfg
.
getUndoBufferSize
()
);
table
->
field
[
c
]
->
store
(
extra
,
len
,
system_charset_info
);
schema_table_store_record
(
thd
,
table
);
}
...
...
sql/mysqld.cc
View file @
829772b4
...
...
@@ -6156,7 +6156,8 @@ The minimum value for this variable is 4096.",
"Each thread that does a sequential scan allocates a buffer of this size for each table it scans. If you do many sequential scans, you may want to increase this value."
,
(
gptr
*
)
&
global_system_variables
.
read_buff_size
,
(
gptr
*
)
&
max_system_variables
.
read_buff_size
,
0
,
GET_ULONG
,
REQUIRED_ARG
,
128
*
1024L
,
IO_SIZE
*
2
+
MALLOC_OVERHEAD
,
~
0L
,
MALLOC_OVERHEAD
,
IO_SIZE
,
0
},
128
*
1024L
,
IO_SIZE
*
2
+
MALLOC_OVERHEAD
,
SSIZE_MAX
,
MALLOC_OVERHEAD
,
IO_SIZE
,
0
},
{
"read_only"
,
OPT_READONLY
,
"Make all non-temporary tables read-only, with the exception for replication (slave) threads and users with the SUPER privilege"
,
(
gptr
*
)
&
opt_readonly
,
...
...
@@ -6167,12 +6168,12 @@ The minimum value for this variable is 4096.",
(
gptr
*
)
&
global_system_variables
.
read_rnd_buff_size
,
(
gptr
*
)
&
max_system_variables
.
read_rnd_buff_size
,
0
,
GET_ULONG
,
REQUIRED_ARG
,
256
*
1024L
,
IO_SIZE
*
2
+
MALLOC_OVERHEAD
,
~
0L
,
MALLOC_OVERHEAD
,
IO_SIZE
,
0
},
SSIZE_MAX
,
MALLOC_OVERHEAD
,
IO_SIZE
,
0
},
{
"record_buffer"
,
OPT_RECORD_BUFFER
,
"Alias for read_buffer_size"
,
(
gptr
*
)
&
global_system_variables
.
read_buff_size
,
(
gptr
*
)
&
max_system_variables
.
read_buff_size
,
0
,
GET_ULONG
,
REQUIRED_ARG
,
128
*
1024L
,
IO_SIZE
*
2
+
MALLOC_OVERHEAD
,
~
0L
,
MALLOC_OVERHEAD
,
IO_SIZE
,
0
},
128
*
1024L
,
IO_SIZE
*
2
+
MALLOC_OVERHEAD
,
SSIZE_MAX
,
MALLOC_OVERHEAD
,
IO_SIZE
,
0
},
#ifdef HAVE_REPLICATION
{
"relay_log_purge"
,
OPT_RELAY_LOG_PURGE
,
"0 = do not purge relay logs. 1 = purge them as soon as they are no more needed."
,
...
...
sql/sql_show.cc
View file @
829772b4
...
...
@@ -438,6 +438,7 @@ mysql_find_files(THD *thd,List<char> *files, const char *db,const char *path,
uint
col_access
=
thd
->
col_access
;
#endif
TABLE_LIST
table_list
;
char
tbbuff
[
FN_REFLEN
];
DBUG_ENTER
(
"mysql_find_files"
);
if
(
wild
&&
!
wild
[
0
])
...
...
@@ -454,6 +455,8 @@ mysql_find_files(THD *thd,List<char> *files, const char *db,const char *path,
DBUG_RETURN
(
-
1
);
}
VOID
(
tablename_to_filename
(
tmp_file_prefix
,
tbbuff
,
sizeof
(
tbbuff
)));
for
(
i
=
0
;
i
<
(
uint
)
dirp
->
number_off_files
;
i
++
)
{
char
uname
[
NAME_LEN
*
3
+
1
];
/* Unencoded name */
...
...
@@ -491,7 +494,7 @@ mysql_find_files(THD *thd,List<char> *files, const char *db,const char *path,
{
// Return only .frm files which aren't temp files.
if
(
my_strcasecmp
(
system_charset_info
,
ext
=
fn_rext
(
file
->
name
),
reg_ext
)
||
is_prefix
(
file
->
name
,
t
mp_file_prefix
))
is_prefix
(
file
->
name
,
t
bbuff
))
continue
;
*
ext
=
0
;
VOID
(
filename_to_tablename
(
file
->
name
,
uname
,
sizeof
(
uname
)));
...
...
storage/myisam/ft_parser.c
View file @
829772b4
...
...
@@ -111,6 +111,7 @@ byte ft_get_word(CHARSET_INFO *cs, byte **start, byte *end,
FT_WORD
*
word
,
MYSQL_FTPARSER_BOOLEAN_INFO
*
param
)
{
byte
*
doc
=*
start
;
int
ctype
;
uint
mwc
,
length
,
mbl
;
param
->
yesno
=
(
FTB_YES
==
' '
)
?
1
:
(
param
->
quot
!=
0
);
...
...
@@ -119,9 +120,11 @@ byte ft_get_word(CHARSET_INFO *cs, byte **start, byte *end,
while
(
doc
<
end
)
{
for
(;
doc
<
end
;
doc
++
)
for
(;
doc
<
end
;
doc
+=
(
mbl
>
0
?
mbl
:
1
)
)
{
if
(
true_word_char
(
cs
,
*
doc
))
break
;
mbl
=
cs
->
cset
->
ctype
(
cs
,
&
ctype
,
(
uchar
*
)
doc
,
(
uchar
*
)
end
);
if
(
true_word_char
(
ctype
,
*
doc
))
break
;
if
(
*
doc
==
FTB_RQUOT
&&
param
->
quot
)
{
param
->
quot
=
doc
;
...
...
@@ -155,14 +158,16 @@ byte ft_get_word(CHARSET_INFO *cs, byte **start, byte *end,
}
mwc
=
length
=
0
;
for
(
word
->
pos
=
doc
;
doc
<
end
;
length
++
,
mbl
=
my_mbcharlen
(
cs
,
*
(
uchar
*
)
doc
),
doc
+=
(
mbl
?
mbl
:
1
))
if
(
true_word_char
(
cs
,
*
doc
))
for
(
word
->
pos
=
doc
;
doc
<
end
;
length
++
,
doc
+=
(
mbl
>
0
?
mbl
:
1
))
{
mbl
=
cs
->
cset
->
ctype
(
cs
,
&
ctype
,
(
uchar
*
)
doc
,
(
uchar
*
)
end
);
if
(
true_word_char
(
ctype
,
*
doc
))
mwc
=
0
;
else
if
(
!
misc_word_char
(
*
doc
)
||
mwc
)
break
;
else
mwc
++
;
}
param
->
prev
=
'A'
;
/* be sure *prev is true_word_char */
word
->
len
=
(
uint
)(
doc
-
word
->
pos
)
-
mwc
;
if
((
param
->
trunc
=
(
doc
<
end
&&
*
doc
==
FTB_TRUNC
)))
...
...
@@ -197,24 +202,31 @@ byte ft_simple_get_word(CHARSET_INFO *cs, byte **start, const byte *end,
{
byte
*
doc
=
*
start
;
uint
mwc
,
length
,
mbl
;
int
ctype
;
DBUG_ENTER
(
"ft_simple_get_word"
);
do
{
for
(;;
doc
+
+
)
for
(;;
doc
+
=
(
mbl
>
0
?
mbl
:
1
)
)
{
if
(
doc
>=
end
)
DBUG_RETURN
(
0
);
if
(
true_word_char
(
cs
,
*
doc
))
break
;
if
(
doc
>=
end
)
DBUG_RETURN
(
0
);
mbl
=
cs
->
cset
->
ctype
(
cs
,
&
ctype
,
(
uchar
*
)
doc
,
(
uchar
*
)
end
);
if
(
true_word_char
(
ctype
,
*
doc
))
break
;
}
mwc
=
length
=
0
;
for
(
word
->
pos
=
doc
;
doc
<
end
;
length
++
,
mbl
=
my_mbcharlen
(
cs
,
*
(
uchar
*
)
doc
),
doc
+=
(
mbl
?
mbl
:
1
))
if
(
true_word_char
(
cs
,
*
doc
))
for
(
word
->
pos
=
doc
;
doc
<
end
;
length
++
,
doc
+=
(
mbl
>
0
?
mbl
:
1
))
{
mbl
=
cs
->
cset
->
ctype
(
cs
,
&
ctype
,
(
uchar
*
)
doc
,
(
uchar
*
)
end
);
if
(
true_word_char
(
ctype
,
*
doc
))
mwc
=
0
;
else
if
(
!
misc_word_char
(
*
doc
)
||
mwc
)
break
;
else
mwc
++
;
}
word
->
len
=
(
uint
)(
doc
-
word
->
pos
)
-
mwc
;
...
...
storage/myisam/ft_update.c
View file @
829772b4
...
...
@@ -174,11 +174,6 @@ int _mi_ft_cmp(MI_INFO *info, uint keynr, const byte *rec1, const byte *rec2)
FT_SEG_ITERATOR
ftsi1
,
ftsi2
;
CHARSET_INFO
*
cs
=
info
->
s
->
keyinfo
[
keynr
].
seg
->
charset
;
DBUG_ENTER
(
"_mi_ft_cmp"
);
#ifndef MYSQL_HAS_TRUE_CTYPE_IMPLEMENTATION
if
(
cs
->
mbmaxlen
>
1
)
DBUG_RETURN
(
THOSE_TWO_DAMN_KEYS_ARE_REALLY_DIFFERENT
);
#endif
_mi_ft_segiterator_init
(
info
,
keynr
,
rec1
,
&
ftsi1
);
_mi_ft_segiterator_init
(
info
,
keynr
,
rec2
,
&
ftsi2
);
...
...
storage/myisam/ftdefs.h
View file @
829772b4
...
...
@@ -24,9 +24,10 @@
#include <queues.h>
#include <mysql/plugin.h>
#define true_word_char(s,X) (my_isalnum(s,X) || (X)=='_')
#define true_word_char(ctype, character) \
((ctype) & (_MY_U | _MY_L | _MY_NMR) || \
(character) == '_')
#define misc_word_char(X) 0
#define word_char(s,X) (true_word_char(s,X) || misc_word_char(X))
#define FT_MAX_WORD_LEN_FOR_SORT 31
...
...
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