~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_base.h

  • Committer: Monty Taylor
  • Date: 2010-12-27 19:58:09 UTC
  • mto: This revision was merged to the branch mainline in revision 2038.
  • Revision ID: mordred@inaugust.com-20101227195809-1k7a4ge19l3u1o1h
Updated pandora-build files to version 0.171

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
2
2
 *  vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
3
3
 *
4
 
 *  Copyright (C) 2008 Sun Microsystems
 
4
 *  Copyright (C) 2008 Sun Microsystems, Inc.
5
5
 *
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
21
21
#define DRIZZLED_SQL_BASE_H
22
22
 
23
23
#include <drizzled/table.h>
 
24
#include <drizzled/table/concurrent.h>
24
25
 
25
26
namespace drizzled
26
27
{
29
30
 
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);
35
35
 
 
36
table::Cache &get_open_cache();
 
37
 
36
38
void kill_drizzle(void);
37
39
 
38
40
/* sql_base.cc */
89
91
  RESOLVED_WITH_NO_ALIAS,
90
92
  RESOLVED_AGAINST_ALIAS
91
93
};
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);
133
135
 
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,
140
 
                             uint32_t flags);
141
141
 
142
142
void mem_alloc_error(size_t size);
143
143
 
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,
147
 
                      const char *wild,
148
 
                      bool(*func)(Table *table,
149
 
                                  open_table_list_st& open_list,
150
 
                                  plugin::InfoSchemaTable *schema_table),
151
 
                      Table *display,
152
 
                      plugin::InfoSchemaTable *schema_table);
153
 
 
154
146
inline TableList *find_table_in_global_list(TableList *table,
155
147
                                             const char *db_name,
156
148
                                             const char *table_name)