From be5c432a42eed10535354f31dfd6daa07095e555 Mon Sep 17 00:00:00 2001 From: Kentoku SHIBA Date: Tue, 11 Jun 2019 00:25:08 +0900 Subject: MDEV-16249 CHECKSUM TABLE for a spider table is not parallel and saves all data in memory in the spider head by default (#1328) add checksum_null for setting null value of checksum --- sql/sql_show.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'sql/sql_show.cc') diff --git a/sql/sql_show.cc b/sql/sql_show.cc index adf6544ff3e..bf5bb0ae7d5 100644 --- a/sql/sql_show.cc +++ b/sql/sql_show.cc @@ -5668,7 +5668,9 @@ static int get_schema_tables_record(THD *thd, TABLE_LIST *tables, table->field[16]->store_time(&time); table->field[16]->set_notnull(); } - if (file->ha_table_flags() & (HA_HAS_OLD_CHECKSUM | HA_HAS_NEW_CHECKSUM)) + if ((file->ha_table_flags() & + (HA_HAS_OLD_CHECKSUM | HA_HAS_NEW_CHECKSUM)) && + !file->stats.checksum_null) { table->field[18]->store((longlong) file->stats.checksum, TRUE); table->field[18]->set_notnull(); -- cgit v1.2.1