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
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
20
class Item_row: public Item
23
table_map used_tables_cache;
25
bool const_item_cache;
28
Item_row(List<Item> &);
29
Item_row(Item_row *item):
32
used_tables_cache(item->used_tables_cache),
33
arg_count(item->arg_count),
34
const_item_cache(item->const_item_cache),
38
enum Type type() const { return ROW_ITEM; };
39
void illegal_method_call(const char *);
40
bool is_null() { return null_value; }
41
void make_field(Send_field *)
43
illegal_method_call((const char*)"make_field");
47
illegal_method_call((const char*)"val");
52
illegal_method_call((const char*)"val_int");
55
String *val_str(String *)
57
illegal_method_call((const char*)"val_str");
60
my_decimal *val_decimal(my_decimal *)
62
illegal_method_call((const char*)"val_decimal");
65
bool fix_fields(Session *session, Item **ref);
66
void fix_after_pullout(st_select_lex *new_parent, Item **ref);
68
void split_sum_func(Session *session, Item **ref_pointer_array, List<Item> &fields);
69
table_map used_tables() const { return used_tables_cache; };
70
bool const_item() const { return const_item_cache; };
71
enum Item_result result_type() const { return ROW_RESULT; }
72
void update_used_tables();
73
virtual void print(String *str, enum_query_type query_type);
75
bool walk(Item_processor processor, bool walk_subquery, unsigned char *arg);
76
Item *transform(Item_transformer transformer, unsigned char *arg);
78
uint32_t cols() { return arg_count; }
79
Item* element_index(uint32_t i) { return items[i]; }
80
Item** addr(uint32_t i) { return items + i; }
81
bool check_cols(uint32_t c);
82
bool null_inside() { return with_null; };
84
bool check_vcol_func_processor(unsigned char *int_arg __attribute__((unused)))