mirror of
https://github.com/MariaDB/server.git
synced 2025-01-17 12:32:27 +01:00
bd365f7622
Add support for warnings for prepare of prepared statements Fixed test to work with --ps-protocol Fixed some test results libmysql/libmysql.c: Add support for warnings for prepare of prepared statements mysql-test/r/func_concat.result: After merge fixes mysql-test/r/select.result: Delete conflicting tables form previous tests mysql-test/r/view.result: New code from 4.1 fixed old error mysql-test/t/create.test: Ensure that --ps-protocol return same results as normal test mysql-test/t/func_group.test: Remove not needed --disable_ps_protocol mysql-test/t/func_time.test: Ensure that --ps-protocol return same results as normal test mysql-test/t/having.test: Ensure that --ps-protocol return same results as normal test mysql-test/t/insert_select.test: Remove not needed --disable_ps_protocol mysql-test/t/select.test: Ensure that --ps-protocol return same results as normal test mysql-test/t/sp.test: Fixed comment mysql-test/t/system_mysql_db_fix.test: Fix that results is same as from system_mysql_db.test mysql-test/t/trigger.test: Added comment mysql-test/t/type_blob.test: Remove not needed --disable_ps_protocol mysql-test/t/union.test: Run most of the test with --ps-protocol mysql-test/t/user_limits.test: Ensure that --ps-protocol return same results as normal test mysql-test/t/view.test: Removed --error as bug is now fixed mysql-test/t/warnings.test: Ensure that --ps-protocol return same results as normal test ndb/include/Makefile.am: Don't automaticly use SCCS files sql/ha_ndbcluster.cc: Removed compiler warning sql/log_event.cc: After merge fix sql/sql_class.h: After merge fix sql/sql_insert.cc: After merge fix sql/sql_load.cc: After merge fix sql/sql_prepare.cc: Add support for warnings for prepare of prepared statements sql/sql_update.cc: After merge fixes
90 lines
2.9 KiB
Text
90 lines
2.9 KiB
Text
#
|
|
# This is the test for mysql_fix_privilege_tables
|
|
#
|
|
# Note: If this test fails, don't be confused about the errors reported
|
|
# by mysql-test-run; This shows warnings from generated by
|
|
# mysql_fix_system_tables which should be ignored.
|
|
# Instead, concentrate on the errors in r/system_mysql_db.reject
|
|
|
|
--disable_warnings
|
|
drop table if exists t1,t1aa,t2aa;
|
|
--enable_warnings
|
|
|
|
-- disable_result_log
|
|
-- disable_query_log
|
|
|
|
use test;
|
|
|
|
# create system tables as in mysql-3.20
|
|
|
|
--disable_warnings
|
|
CREATE TABLE db (
|
|
Host char(60) binary DEFAULT '' NOT NULL,
|
|
Db char(32) binary DEFAULT '' NOT NULL,
|
|
User char(16) binary DEFAULT '' NOT NULL,
|
|
Select_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Insert_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Update_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Delete_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Create_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Drop_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
PRIMARY KEY Host (Host,Db,User),
|
|
KEY User (User)
|
|
)
|
|
type=ISAM;
|
|
--enable-warnings
|
|
|
|
INSERT INTO db VALUES ('%','test', '','Y','Y','Y','Y','Y','Y');
|
|
INSERT INTO db VALUES ('%','test\_%','','Y','Y','Y','Y','Y','Y');
|
|
|
|
--disable_warnings
|
|
CREATE TABLE host (
|
|
Host char(60) binary DEFAULT '' NOT NULL,
|
|
Db char(32) binary DEFAULT '' NOT NULL,
|
|
Select_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Insert_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Update_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Delete_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Create_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Drop_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
PRIMARY KEY Host (Host,Db)
|
|
)
|
|
type=ISAM;
|
|
--enable-warnings
|
|
|
|
--disable_warnings
|
|
CREATE TABLE user (
|
|
Host char(60) binary DEFAULT '' NOT NULL,
|
|
User char(16) binary DEFAULT '' NOT NULL,
|
|
Password char(16),
|
|
Select_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Insert_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Update_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Delete_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Create_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Drop_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Reload_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Shutdown_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
Process_priv enum('N','Y') DEFAULT 'N' NOT NULL,
|
|
PRIMARY KEY Host (Host,User)
|
|
)
|
|
type=ISAM;
|
|
--enable-warnings
|
|
|
|
INSERT INTO user VALUES ('localhost','root','','Y','Y','Y','Y','Y','Y','Y','Y','Y');
|
|
INSERT INTO user VALUES ('localhost','', '','N','N','N','N','N','N','N','N','N');
|
|
|
|
-- exec $MYSQL_FIX_SYSTEM_TABLES --database=test
|
|
-- enable_query_log
|
|
-- enable_result_log
|
|
|
|
-- source include/system_db_struct.inc
|
|
|
|
-- disable_query_log
|
|
|
|
DROP TABLE db, host, user, func, tables_priv, columns_priv, procs_priv, help_category, help_keyword, help_relation, help_topic, proc, time_zone, time_zone_leap_second, time_zone_name, time_zone_transition, time_zone_transition_type;
|
|
|
|
-- enable_query_log
|
|
|
|
# check that we droped all system tables
|
|
show tables;
|