1
1
/* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
2
2
* vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
4
* Copyright (C) 2008 Sun Microsystems
4
* Copyright (C) 2008 Sun Microsystems, Inc.
6
6
* This program is free software; you can redistribute it and/or modify
7
7
* it under the terms of the GNU General Public License as published by
30
31
void table_cache_free(void);
31
32
bool table_cache_init(void);
32
void assign_new_table_id(TableShare *share);
33
33
uint32_t cached_open_tables(void);
34
34
uint32_t cached_table_definitions(void);
36
table::Cache &get_open_cache();
36
38
void kill_drizzle(void);
89
91
RESOLVED_WITH_NO_ALIAS,
90
92
RESOLVED_AGAINST_ALIAS
92
Item ** find_item_in_list(Item *item, List<Item> &items, uint32_t *counter,
94
Item ** find_item_in_list(Session *session,
95
Item *item, List<Item> &items, uint32_t *counter,
93
96
find_item_error_report_type report_error,
94
97
enum_resolution_type *resolution);
95
98
bool insert_fields(Session *session, Name_resolution_context *context,
129
132
const char *table_name);
130
133
TableList *unique_table(TableList *table, TableList *table_list,
131
134
bool check_alias= false);
132
void remove_db_from_cache(const char *db);
134
/* bits for last argument to remove_table_from_cache() */
136
/* bits for last argument to table::Cache::singleton().removeTable() */
135
137
#define RTFC_NO_FLAG 0x0000
136
138
#define RTFC_OWNED_BY_Session_FLAG 0x0001
137
139
#define RTFC_WAIT_OTHER_THREAD_FLAG 0x0002
138
140
#define RTFC_CHECK_KILLED_FLAG 0x0004
139
bool remove_table_from_cache(Session *session, const char *db, const char *table,
142
142
void mem_alloc_error(size_t size);
144
144
bool fill_record(Session* session, List<Item> &fields, List<Item> &values, bool ignore_errors= false);
145
145
bool fill_record(Session *session, Field **field, List<Item> &values, bool ignore_errors= false);
146
bool list_open_tables(const char *db,
148
bool(*func)(Table *table,
149
open_table_list_st& open_list,
150
plugin::InfoSchemaTable *schema_table),
152
plugin::InfoSchemaTable *schema_table);
154
146
inline TableList *find_table_in_global_list(TableList *table,
155
147
const char *db_name,
156
148
const char *table_name)