Commit 62dab7cf authored by unknown's avatar unknown

some fixes from review of WL1359.

fix up test cases.


mysql-test/r/information_schema.result:
  update result for INFORMATION_SCHEMA.FILES
mysql-test/r/information_schema_db.result:
  update result for INFORMATION_SCHEMA.FILES
sql/ha_ndbcluster.cc:
  in fill_files_table, use my_snprintf instead of snprintf
sql/sql_show.cc:
  correct DBUG_ENTER for fill_schema_files
sql/table.h:
  add SCH_FILES to information schema enum
parent 4228d966
......@@ -45,6 +45,7 @@ COLUMNS
COLUMN_PRIVILEGES
ENGINES
EVENTS
FILES
KEY_COLUMN_USAGE
PARTITIONS
PLUGINS
......@@ -735,7 +736,7 @@ CREATE TABLE t_crashme ( f1 BIGINT);
CREATE VIEW a1 (t_CRASHME) AS SELECT f1 FROM t_crashme GROUP BY f1;
CREATE VIEW a2 AS SELECT t_CRASHME FROM a1;
count(*)
110
111
drop view a2, a1;
drop table t_crashme;
select table_schema,table_name, column_name from
......@@ -765,6 +766,12 @@ EVENTS ENDS datetime
EVENTS CREATED datetime
EVENTS LAST_ALTERED datetime
EVENTS LAST_EXECUTED datetime
FILES CREATION_TIME datetime
FILES LAST_UPDATE_TIME datetime
FILES LAST_ACCESS_TIME datetime
FILES CREATE_TIME datetime
FILES UPDATE_TIME datetime
FILES CHECK_TIME datetime
PARTITIONS CREATE_TIME datetime
PARTITIONS UPDATE_TIME datetime
PARTITIONS CHECK_TIME datetime
......@@ -813,6 +820,7 @@ where COLUMN_NAME='TABLE_NAME';
TABLE_NAME COLUMN_NAME PRIVILEGES
COLUMNS TABLE_NAME select
COLUMN_PRIVILEGES TABLE_NAME select
FILES TABLE_NAME select
KEY_COLUMN_USAGE TABLE_NAME select
PARTITIONS TABLE_NAME select
STATISTICS TABLE_NAME select
......@@ -826,7 +834,7 @@ flush privileges;
SELECT table_schema, count(*) FROM information_schema.TABLES GROUP BY TABLE_SCHEMA;
table_schema count(*)
cluster_replication 1
information_schema 20
information_schema 21
mysql 21
create table t1 (i int, j int);
create trigger trg1 before insert on t1 for each row
......
......@@ -8,6 +8,7 @@ COLUMNS
COLUMN_PRIVILEGES
ENGINES
EVENTS
FILES
KEY_COLUMN_USAGE
PARTITIONS
PLUGINS
......
......@@ -9666,7 +9666,7 @@ static int ndbcluster_fill_files_table(THD *thd, TABLE_LIST *tables, COND *cond)
table->field[c++]->store("NORMAL",6, system_charset_info);
char extra[30];
int len= snprintf(extra,sizeof(extra),"CLUSTER_NODE=%u",id);
int len= my_snprintf(extra,sizeof(extra),"CLUSTER_NODE=%u",id);
table->field[c]->store(extra,len,system_charset_info);
schema_table_store_record(thd, table);
}
......@@ -9741,7 +9741,7 @@ static int ndbcluster_fill_files_table(THD *thd, TABLE_LIST *tables, COND *cond)
table->field[c++]->store("NORMAL",6, system_charset_info);
char extra[30];
int len= snprintf(extra,sizeof(extra),"CLUSTER_NODE=%u",id);
int len= my_snprintf(extra,sizeof(extra),"CLUSTER_NODE=%u",id);
table->field[c]->store(extra,len,system_charset_info);
schema_table_store_record(thd, table);
}
......
......@@ -4586,7 +4586,7 @@ int fill_schema_files(THD *thd, TABLE_LIST *tables, COND *cond)
{
int i;
TABLE *table= tables->table;
DBUG_ENTER("fill_schema_logfile_groups");
DBUG_ENTER("fill_schema_files");
struct run_hton_fill_schema_files_args args;
args.tables= tables;
......
......@@ -339,6 +339,7 @@ enum enum_schema_tables
SCH_COLUMN_PRIVILEGES,
SCH_ENGINES,
SCH_EVENTS,
SCH_FILES,
SCH_KEY_COLUMN_USAGE,
SCH_OPEN_TABLES,
SCH_PARTITIONS,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment