851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
1 |
/* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
|
2 |
* vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
|
|
3 |
*
|
|
4 |
* Copyright (C) 2008 Sun Microsystems
|
|
5 |
*
|
|
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.
|
|
9 |
*
|
|
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.
|
|
14 |
*
|
|
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
|
|
18 |
*/
|
|
19 |
||
20 |
||
21 |
#ifndef DRIZZLED_TMP_TABLE_PARAM_H
|
|
22 |
#define DRIZZLED_TMP_TABLE_PARAM_H
|
|
23 |
||
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
24 |
namespace drizzled |
25 |
{
|
|
26 |
||
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
27 |
/*
|
28 |
Param to create temporary tables when doing SELECT:s
|
|
29 |
NOTE
|
|
30 |
This structure is copied using memcpy as a part of JOIN.
|
|
31 |
*/
|
|
32 |
||
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
33 |
class Tmp_Table_Param :public memory::SqlAlloc |
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
34 |
{
|
35 |
private: |
|
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 &); |
|
39 |
||
40 |
public: |
|
1030.1.3
by Brian Aker
Final bits to structure alignment |
41 |
KEY *keyinfo; |
1101.1.16
by Monty Taylor
Reverted 1103 |
42 |
List<Item> copy_funcs; |
43 |
List<Item> save_copy_funcs; |
|
1052.2.2
by Nathan Williams
No actual code changes. Changed Copy_field to CopyField, to reflect the coding standards. |
44 |
CopyField *copy_field, *copy_field_end; |
45 |
CopyField *save_copy_field, *save_copy_field_end; |
|
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
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; |
|
1030.1.3
by Brian Aker
Final bits to structure alignment |
50 |
uint32_t field_count; |
51 |
uint32_t sum_func_count; |
|
52 |
uint32_t func_count; |
|
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
53 |
uint32_t hidden_field_count; |
1030.1.3
by Brian Aker
Final bits to structure alignment |
54 |
uint32_t group_parts,group_length,group_null_parts; |
55 |
uint32_t quick_group; |
|
56 |
bool using_indirect_summary_function; |
|
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
57 |
bool schema_table; |
1030.1.3
by Brian Aker
Final bits to structure alignment |
58 |
|
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
59 |
/*
|
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.
|
|
64 |
*/
|
|
65 |
bool precomputed_group_by; |
|
1030.1.3
by Brian Aker
Final bits to structure alignment |
66 |
|
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
67 |
bool force_copy_fields; |
1030.1.3
by Brian Aker
Final bits to structure alignment |
68 |
|
69 |
/* If >0 convert all blob fields to varchar(convert_blob_length) */
|
|
70 |
uint32_t convert_blob_length; |
|
71 |
||
72 |
const CHARSET_INFO *table_charset; |
|
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
73 |
|
74 |
Tmp_Table_Param() |
|
1101.1.16
by Monty Taylor
Reverted 1103 |
75 |
:copy_field(0), |
76 |
group_parts(0), |
|
77 |
group_length(0), |
|
78 |
group_null_parts(0), |
|
79 |
schema_table(false), |
|
80 |
precomputed_group_by(false), |
|
81 |
force_copy_fields(false), |
|
1273.2.2
by Stewart Smith
it turns out that bit_fields_as_long in tmp_table_param is in fact unused. remove it. |
82 |
convert_blob_length(0) |
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
83 |
{}
|
84 |
~Tmp_Table_Param() |
|
85 |
{
|
|
1101.1.16
by Monty Taylor
Reverted 1103 |
86 |
cleanup(); |
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
87 |
}
|
1101.1.16
by Monty Taylor
Reverted 1103 |
88 |
void init(void); |
89 |
void cleanup(void); |
|
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
90 |
};
|
91 |
||
1280.1.10
by Monty Taylor
Put everything in drizzled into drizzled namespace. |
92 |
} /* namespace drizzled */ |
93 |
||
851
by Brian Aker
Class rewrite of Session (aka get all of the junk out) |
94 |
#endif /* DRIZZLED_TMP_TABLE_PARAM_H */ |