mirror of
https://github.com/MariaDB/server.git
synced 2025-01-18 13:02:28 +01:00
20c3b2ff80
fail CREATE SERVER foreign data wrapper is "mysql" and neither HOST nor SOCKET are specified. Also default PORT to 3306 (again, only for foreign data wrapper "mysql")
25 lines
1,011 B
Text
25 lines
1,011 B
Text
#
|
|
# MDEV-4594 - CREATE SERVER crashes embedded
|
|
#
|
|
CREATE SERVER s1 FOREIGN DATA WRAPPER mysql OPTIONS(HOST 'localhost');
|
|
SELECT * FROM mysql.servers;
|
|
Server_name Host Db Username Password Port Socket Wrapper Owner
|
|
s1 localhost 3306 mysql
|
|
DROP SERVER s1;
|
|
CREATE SERVER s1 FOREIGN DATA WRAPPER foo OPTIONS(USER 'bar');
|
|
SELECT * FROM mysql.servers;
|
|
Server_name Host Db Username Password Port Socket Wrapper Owner
|
|
s1 bar 0 foo
|
|
DROP SERVER s1;
|
|
CREATE SERVER s1 FOREIGN DATA WRAPPER mysql OPTIONS(USER 'bar');
|
|
ERROR HY000: Can't create federated table. Foreign data src error: either HOST or SOCKET must be set
|
|
CREATE SERVER s1 FOREIGN DATA WRAPPER mysql OPTIONS(HOST 'bar');
|
|
SELECT * FROM mysql.servers;
|
|
Server_name Host Db Username Password Port Socket Wrapper Owner
|
|
s1 bar 3306 mysql
|
|
DROP SERVER s1;
|
|
CREATE SERVER s1 FOREIGN DATA WRAPPER mysql OPTIONS(SOCKET 'bar');
|
|
SELECT * FROM mysql.servers;
|
|
Server_name Host Db Username Password Port Socket Wrapper Owner
|
|
s1 3306 bar mysql
|
|
DROP SERVER s1;
|