1
/* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
2
* vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
4
* Copyright (C) 2008 Sun Microsystems, Inc.
6
* This program is free software; you can redistribute it and/or modify
7
* it under the terms of the GNU General Public License as published by
8
* the Free Software Foundation; version 2 of the License.
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
15
* You should have received a copy of the GNU General Public License
16
* along with this program; if not, write to the Free Software
17
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
21
#ifndef DRIZZLED_TMP_TABLE_PARAM_H
22
#define DRIZZLED_TMP_TABLE_PARAM_H
28
Param to create temporary tables when doing SELECT:s
30
This structure is copied using memcpy as a part of JOIN.
33
class Tmp_Table_Param :public memory::SqlAlloc
36
/* Prevent use of these (not safe because of lists and copy_field) */
37
Tmp_Table_Param(const Tmp_Table_Param &);
38
void operator=(Tmp_Table_Param &);
42
List<Item> copy_funcs;
43
List<Item> save_copy_funcs;
44
CopyField *copy_field, *copy_field_end;
45
CopyField *save_copy_field, *save_copy_field_end;
46
unsigned char *group_buff;
47
Item **items_to_copy; /* Fields in tmp table */
48
MI_COLUMNDEF *recinfo,*start_recinfo;
49
ha_rows end_write_records;
51
uint32_t sum_func_count;
53
uint32_t hidden_field_count;
54
uint32_t group_parts,group_length,group_null_parts;
56
bool using_indirect_summary_function;
60
True if GROUP BY and its aggregate functions are already computed
61
by a table access method (e.g. by loose index scan). In this case
62
query execution should not perform aggregation and should treat
63
aggregate functions as normal functions.
65
bool precomputed_group_by;
67
bool force_copy_fields;
69
/* If >0 convert all blob fields to varchar(convert_blob_length) */
70
uint32_t convert_blob_length;
72
const CHARSET_INFO *table_charset;
81
save_copy_field_end(0),
90
hidden_field_count(0),
95
using_indirect_summary_function(false),
97
precomputed_group_by(false),
98
force_copy_fields(false),
99
convert_blob_length(0),
111
} /* namespace drizzled */
113
#endif /* DRIZZLED_TMP_TABLE_PARAM_H */