diff options
author | unknown <monty@mysql.com> | 2005-01-06 13:00:13 +0200 |
---|---|---|
committer | unknown <monty@mysql.com> | 2005-01-06 13:00:13 +0200 |
commit | ff6097bd8ad42da14193d3f63fcd0f561d4300d9 (patch) | |
tree | ed8b3e5bd637f4d9661ed2ba57849e7e56d5178a /sql/sql_help.cc | |
parent | af8301ce38e8cf6be969647714b869eba60cb45c (diff) | |
download | mariadb-git-ff6097bd8ad42da14193d3f63fcd0f561d4300d9.tar.gz |
First stage of table definition cache
Split TABLE to TABLE and TABLE_SHARE (TABLE_SHARE is still allocated as part of table, will be fixed soon)
Created Field::make_field() and made Field_num::make_field() to call this
Added 'TABLE_SHARE->db' that points to database name; Changed all usage of table_cache_key as database name to use this instead
Changed field->table_name to point to pointer to alias. This allows us to change alias for a table by just updating one pointer.
Renamed TABLE_SHARE->real_name to table_name
Renamed TABLE->table_name to alias
Renamed TABLE_LIST->real_name to table_name
include/myisam.h:
Added const before names
mysql-test/r/group_min_max.result:
Make results repeatable
mysql-test/t/group_min_max.test:
Make results repeatable
sql/field.cc:
Created Field::make_field() and made Field_num::make_field() to call this
Use TABLE_SHARE
Use sql_strmake() instead of sql_memdup() to simplify code
sql/field.h:
Changed table_name to be pointer to table_name. This allows us to change alias for all fields by just changing one pointer.
Use TABLE_SHARE
sql/field_conv.cc:
Use TABLE_SHARE
sql/filesort.cc:
Use TABLE_SHARE
sql/ha_berkeley.cc:
Use TABLE_SHARE
sql/ha_heap.cc:
Use TABLE_SHARE
sql/ha_innodb.cc:
Use TABLE_SHARE
sql/ha_myisam.cc:
Use TABLE_SHARE
sql/ha_myisammrg.cc:
Use TABLE_SHARE
Change some pointer handling to use const char*
sql/ha_ndbcluster.cc:
Use TABLE_SHARE
sql/handler.cc:
Use TABLE_SHARE
sql/item.cc:
Use TABLE_SHARE
sql/item_func.cc:
Use TABLE_SHARE
sql/item_subselect.cc:
Use TABLE_SHARE
sql/item_sum.cc:
Use TABLE_SHARE
sql/key.cc:
Use TABLE_SHARE
sql/lock.cc:
Use TABLE_SHARE
sql/log_event.cc:
real_name -> table_name
sql/mysql_priv.h:
Use TABLE_SHARE
sql/opt_range.cc:
Use TABLE_SHARE
sql/opt_sum.cc:
Use TABLE_SHARE
sql/records.cc:
Use TABLE_SHARE
sql/repl_failsafe.cc:
real_name -> table_name
sql/slave.cc:
Use TABLE_SHARE
sql/sp.cc:
Use TABLE_SHARE
sql/sp_head.cc:
real_name -> table_name
sql/sql_acl.cc:
Use TABLE_SHARE
removed unnecessary assert
fixed indentation
changed some char * -> const char*
sql/sql_acl.h:
changed some char* -> const char*
sql/sql_base.cc:
Use TABLE_SHARE
sql/sql_cache.cc:
Use TABLE_SHARE
sql/sql_class.cc:
Use TABLE_SHARE
sql/sql_db.cc:
real_name -> table_name
sql/sql_delete.cc:
Use TABLE_SHARE
sql/sql_derived.cc:
Use TABLE_SHARE
sql/sql_handler.cc:
Use TABLE_SHARE
sql/sql_help.cc:
Use TABLE_SHARE
sql/sql_insert.cc:
Use TABLE_SHARE
sql/sql_load.cc:
Use TABLE_SHARE
sql/sql_parse.cc:
Use TABLE_SHARE
sql/sql_rename.cc:
real_name -> table_name
sql/sql_select.cc:
Use TABLE_SHARE
table->blob_fields now points to field offsets, not fields
tmp_table->table_name now points to alias name
sql/sql_show.cc:
Use TABLE_SHARE
sql/sql_table.cc:
Use TABLE_SHARE
sql/sql_test.cc:
Use TABLE_SHARE
sql/sql_trigger.cc:
Use TABLE_SHARE
sql/sql_udf.cc:
Use TABLE_SHARE
sql/sql_union.cc:
real_name -> table_name
sql/sql_update.cc:
Use TABLE_SHARE
sql/sql_view.cc:
Use TABLE_SHARE
sql/table.cc:
Split TABLE to TABLE and TABLE_SHARE
Changed blob_field to be field offsets instead of pointer to fields
Only initialize table->s->default_values with default record (not all table->record[#])
Some indentation changes
sql/table.h:
Split TABLE to TABLE and TABLE_SHARE
sql/tztime.cc:
real_name -> table_name
sql/unireg.cc:
Use TABLE_SHARE
sql/unireg.h:
Use TABLE_SHARE
Diffstat (limited to 'sql/sql_help.cc')
-rw-r--r-- | sql/sql_help.cc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/sql/sql_help.cc b/sql/sql_help.cc index 99273b42f2a..7bf28a439b6 100644 --- a/sql/sql_help.cc +++ b/sql/sql_help.cc @@ -272,9 +272,9 @@ int get_topics_for_keyword(THD *thd, TABLE *topics, TABLE *relations, DBUG_ENTER("get_topics_for_keyword"); if ((iindex_topic= find_type((char*) primary_key_name, - &topics->keynames, 1+2)-1)<0 || + &topics->s->keynames, 1+2)-1)<0 || (iindex_relations= find_type((char*) primary_key_name, - &relations->keynames, 1+2)-1)<0) + &relations->s->keynames, 1+2)-1)<0) { my_message(ER_CORRUPT_HELP_DB, ER(ER_CORRUPT_HELP_DB), MYF(0)); DBUG_RETURN(-1); @@ -620,16 +620,16 @@ bool mysqld_help(THD *thd, const char *mask) TABLE_LIST *leaves= 0; TABLE_LIST tables[4]; bzero((gptr)tables,sizeof(tables)); - tables[0].alias= tables[0].real_name= (char*) "help_topic"; + tables[0].alias= tables[0].table_name= (char*) "help_topic"; tables[0].lock_type= TL_READ; tables[0].next_global= tables[0].next_local= &tables[1]; - tables[1].alias= tables[1].real_name= (char*) "help_category"; + tables[1].alias= tables[1].table_name= (char*) "help_category"; tables[1].lock_type= TL_READ; tables[1].next_global= tables[1].next_local= &tables[2]; - tables[2].alias= tables[2].real_name= (char*) "help_relation"; + tables[2].alias= tables[2].table_name= (char*) "help_relation"; tables[2].lock_type= TL_READ; tables[2].next_global= tables[2].next_local= &tables[3]; - tables[3].alias= tables[3].real_name= (char*) "help_keyword"; + tables[3].alias= tables[3].table_name= (char*) "help_keyword"; tables[3].lock_type= TL_READ; tables[0].db= tables[1].db= tables[2].db= tables[3].db= (char*) "mysql"; |