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
a3db08d4
Commit
a3db08d4
authored
May 23, 2003
by
bar@bar.mysql.r18.ru
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More tests for system functions
parent
ff02bddc
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
64 additions
and
4 deletions
+64
-4
mysql-test/r/func_system.result
mysql-test/r/func_system.result
+45
-3
mysql-test/t/func_system.test
mysql-test/t/func_system.test
+19
-1
No files found.
mysql-test/r/func_system.result
View file @
a3db08d4
select database(),user() like "%@%";
database() user() like "%@%"
test 1
select database();
database()
test
select charset(database());
charset(database())
utf8
select database() = "test";
database() = "test"
1
select database() = _utf8"test";
database() = _utf8"test"
1
select database() = _latin1"test";
database() = _latin1"test"
1
select user() like "%@%";
user() like "%@%"
1
select user() like _utf8"%@%";
user() like _utf8"%@%"
1
select user() like _latin1"%@%";
user() like _latin1"%@%"
1
select charset(user());
charset(user())
utf8
select version()>="3.23.29";
version()>="3.23.29"
1
select version()>=_utf8"3.23.29";
version()>=_utf8"3.23.29"
1
select version()>=_latin1"3.23.29";
version()>=_latin1"3.23.29"
1
select charset(version());
charset(version())
utf8
create table t1 select database(), user(), version();
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`database()` char(102) character set utf8 NOT NULL default '',
`user()` char(231) character set utf8 NOT NULL default '',
`version()` char(21) character set utf8 NOT NULL default ''
) TYPE=MyISAM CHARSET=latin1
drop table t1;
select TRUE,FALSE,NULL;
TRUE FALSE NULL
1 0 NULL
mysql-test/t/func_system.test
View file @
a3db08d4
...
...
@@ -2,6 +2,24 @@
# system functions
#
select
database
(),
user
()
like
"%@%"
;
select
database
();
select
charset
(
database
());
select
database
()
=
"test"
;
select
database
()
=
_utf8
"test"
;
select
database
()
=
_latin1
"test"
;
select
user
()
like
"%@%"
;
select
user
()
like
_utf8
"%@%"
;
select
user
()
like
_latin1
"%@%"
;
select
charset
(
user
());
select
version
()
>=
"3.23.29"
;
select
version
()
>=
_utf8
"3.23.29"
;
select
version
()
>=
_latin1
"3.23.29"
;
select
charset
(
version
());
create
table
t1
select
database
(),
user
(),
version
();
show
create
table
t1
;
drop
table
t1
;
select
TRUE
,
FALSE
,
NULL
;
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