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
eaa057e9
Commit
eaa057e9
authored
Mar 24, 2005
by
msvensson@neptunus.(none)
Browse files
Options
Browse Files
Download
Plain Diff
Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into neptunus.(none):/home/msvensson/mysql/mysql-4.1
parents
ccea1af2
15378f83
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
42 additions
and
3 deletions
+42
-3
myisam/myisamchk.c
myisam/myisamchk.c
+2
-2
mysql-test/r/func_str.result
mysql-test/r/func_str.result
+20
-0
mysql-test/t/func_str.test
mysql-test/t/func_str.test
+14
-0
sql/item_func.h
sql/item_func.h
+2
-1
sql/item_strfunc.h
sql/item_strfunc.h
+4
-0
No files found.
myisam/myisamchk.c
View file @
eaa057e9
...
@@ -427,8 +427,8 @@ static void usage(void)
...
@@ -427,8 +427,8 @@ static void usage(void)
can't fix the data file.
\n
\
can't fix the data file.
\n
\
--character-sets-dir=...
\n
\
--character-sets-dir=...
\n
\
Directory where character sets are.
\n
\
Directory where character sets are.
\n
\
--set-c
haracter-set
=name
\n
\
--set-c
ollation
=name
\n
\
Change the c
haracter set
used by the index.
\n
\
Change the c
ollation
used by the index.
\n
\
-q, --quick Faster repair by not modifying the data file.
\n
\
-q, --quick Faster repair by not modifying the data file.
\n
\
One can give a second '-q' to force myisamchk to
\n
\
One can give a second '-q' to force myisamchk to
\n
\
modify the original datafile in case of duplicate keys.
\n
\
modify the original datafile in case of duplicate keys.
\n
\
...
...
mysql-test/r/func_str.result
View file @
eaa057e9
...
@@ -636,6 +636,26 @@ drop table t1;
...
@@ -636,6 +636,26 @@ drop table t1;
select charset(null), collation(null), coercibility(null);
select charset(null), collation(null), coercibility(null);
charset(null) collation(null) coercibility(null)
charset(null) collation(null) coercibility(null)
binary binary 5
binary binary 5
CREATE TABLE t1 (a int, b int);
CREATE TABLE t2 (a int, b int);
INSERT INTO t1 VALUES (1,1),(2,2);
INSERT INTO t2 VALUES (2,2),(3,3);
select t1.*,t2.* from t1 left join t2 on (t1.b=t2.b)
where collation(t2.a) = _utf8'binary' order by t1.a,t2.a;
a b a b
1 1 NULL NULL
2 2 2 2
select t1.*,t2.* from t1 left join t2 on (t1.b=t2.b)
where charset(t2.a) = _utf8'binary' order by t1.a,t2.a;
a b a b
1 1 NULL NULL
2 2 2 2
select t1.*,t2.* from t1 left join t2 on (t1.b=t2.b)
where coercibility(t2.a) = 2 order by t1.a,t2.a;
a b a b
1 1 NULL NULL
2 2 2 2
DROP TABLE t1, t2;
select SUBSTR('abcdefg',3,2);
select SUBSTR('abcdefg',3,2);
SUBSTR('abcdefg',3,2)
SUBSTR('abcdefg',3,2)
cd
cd
...
...
mysql-test/t/func_str.test
View file @
eaa057e9
...
@@ -376,6 +376,20 @@ insert into t1 values (null);
...
@@ -376,6 +376,20 @@ insert into t1 values (null);
select
charset
(
a
),
collation
(
a
),
coercibility
(
a
)
from
t1
;
select
charset
(
a
),
collation
(
a
),
coercibility
(
a
)
from
t1
;
drop
table
t1
;
drop
table
t1
;
select
charset
(
null
),
collation
(
null
),
coercibility
(
null
);
select
charset
(
null
),
collation
(
null
),
coercibility
(
null
);
#
# Make sure OUTER JOIN is not replaced with a regular joun
#
CREATE
TABLE
t1
(
a
int
,
b
int
);
CREATE
TABLE
t2
(
a
int
,
b
int
);
INSERT
INTO
t1
VALUES
(
1
,
1
),(
2
,
2
);
INSERT
INTO
t2
VALUES
(
2
,
2
),(
3
,
3
);
select
t1
.*
,
t2
.*
from
t1
left
join
t2
on
(
t1
.
b
=
t2
.
b
)
where
collation
(
t2
.
a
)
=
_utf8
'binary'
order
by
t1
.
a
,
t2
.
a
;
select
t1
.*
,
t2
.*
from
t1
left
join
t2
on
(
t1
.
b
=
t2
.
b
)
where
charset
(
t2
.
a
)
=
_utf8
'binary'
order
by
t1
.
a
,
t2
.
a
;
select
t1
.*
,
t2
.*
from
t1
left
join
t2
on
(
t1
.
b
=
t2
.
b
)
where
coercibility
(
t2
.
a
)
=
2
order
by
t1
.
a
,
t2
.
a
;
DROP
TABLE
t1
,
t2
;
#
#
# test for SUBSTR
# test for SUBSTR
...
...
sql/item_func.h
View file @
eaa057e9
...
@@ -616,7 +616,8 @@ public:
...
@@ -616,7 +616,8 @@ public:
Item_func_coercibility
(
Item
*
a
)
:
Item_int_func
(
a
)
{}
Item_func_coercibility
(
Item
*
a
)
:
Item_int_func
(
a
)
{}
longlong
val_int
();
longlong
val_int
();
const
char
*
func_name
()
const
{
return
"coercibility"
;
}
const
char
*
func_name
()
const
{
return
"coercibility"
;
}
void
fix_length_and_dec
()
{
max_length
=
10
;
}
void
fix_length_and_dec
()
{
max_length
=
10
;
maybe_null
=
0
;
}
table_map
not_null_tables
()
const
{
return
0
;
}
};
};
class
Item_func_locate
:
public
Item_int_func
class
Item_func_locate
:
public
Item_int_func
...
...
sql/item_strfunc.h
View file @
eaa057e9
...
@@ -641,7 +641,9 @@ public:
...
@@ -641,7 +641,9 @@ public:
{
{
collation
.
set
(
system_charset_info
);
collation
.
set
(
system_charset_info
);
max_length
=
64
*
collation
.
collation
->
mbmaxlen
;
// should be enough
max_length
=
64
*
collation
.
collation
->
mbmaxlen
;
// should be enough
maybe_null
=
0
;
};
};
table_map
not_null_tables
()
const
{
return
0
;
}
};
};
class
Item_func_collation
:
public
Item_str_func
class
Item_func_collation
:
public
Item_str_func
...
@@ -654,7 +656,9 @@ public:
...
@@ -654,7 +656,9 @@ public:
{
{
collation
.
set
(
system_charset_info
);
collation
.
set
(
system_charset_info
);
max_length
=
64
*
collation
.
collation
->
mbmaxlen
;
// should be enough
max_length
=
64
*
collation
.
collation
->
mbmaxlen
;
// should be enough
maybe_null
=
0
;
};
};
table_map
not_null_tables
()
const
{
return
0
;
}
};
};
class
Item_func_crc32
:
public
Item_int_func
class
Item_func_crc32
:
public
Item_int_func
...
...
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