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
e0fc6dc8
Commit
e0fc6dc8
authored
Nov 19, 2016
by
Alexander Barkov
Committed by
GitHub
Nov 19, 2016
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #244 from hholzgra/hartmut-MDEV-726
MDEV-726 - CREATE and ALTER SERVER need to lowercase host name
parents
45049864
86637b25
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
0 deletions
+19
-0
mysql-test/r/create_drop_server.result
mysql-test/r/create_drop_server.result
+9
-0
mysql-test/t/create_drop_server.test
mysql-test/t/create_drop_server.test
+9
-0
sql/sql_yacc.yy
sql/sql_yacc.yy
+1
-0
No files found.
mysql-test/r/create_drop_server.result
View file @
e0fc6dc8
...
...
@@ -35,3 +35,12 @@ SELECT server_name, username, db FROM mysql.servers;
server_name username db
server_1 mysqltest_1 test4
DROP SERVER server_1;
CREATE SERVER server_1 FOREIGN DATA WRAPPER mysql OPTIONS (USER 'Remote', HOST 'Server.Example.Com', DATABASE 'test');
SELECT Host FROM mysql.servers WHERE Server_Name = 'server_1';
Host
server.example.com
ALTER SERVER server_1 OPTIONS(HOST 'Server.Example.Org');
SELECT Host FROM mysql.servers WHERE Server_Name = 'server_1';
Host
server.example.org
DROP SERVER server_1;
mysql-test/t/create_drop_server.test
View file @
e0fc6dc8
...
...
@@ -23,3 +23,12 @@ CREATE OR REPLACE SERVER IF NOT EXISTS server_1 FOREIGN DATA WRAPPER mysql OPTIO
CREATE
OR
REPLACE
SERVER
server_1
FOREIGN
DATA
WRAPPER
mysql
OPTIONS
(
USER
'mysqltest_1'
,
HOST
'localhost'
,
DATABASE
'test4'
);
SELECT
server_name
,
username
,
db
FROM
mysql
.
servers
;
DROP
SERVER
server_1
;
# MDEV-726 convert host names to lowercase
CREATE
SERVER
server_1
FOREIGN
DATA
WRAPPER
mysql
OPTIONS
(
USER
'Remote'
,
HOST
'Server.Example.Com'
,
DATABASE
'test'
);
SELECT
Host
FROM
mysql
.
servers
WHERE
Server_Name
=
'server_1'
;
ALTER
SERVER
server_1
OPTIONS
(
HOST
'Server.Example.Org'
);
SELECT
Host
FROM
mysql
.
servers
WHERE
Server_Name
=
'server_1'
;
DROP
SERVER
server_1
;
sql/sql_yacc.yy
View file @
e0fc6dc8
...
...
@@ -2684,6 +2684,7 @@ server_option:
{
MYSQL_YYABORT_UNLESS(Lex->server_options.host.str == 0);
Lex->server_options.host= $2;
my_casedn_str(system_charset_info, Lex->server_options.host.str);
}
| DATABASE TEXT_STRING_sys
{
...
...
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