Merge lp:~stewart/drizzle/remove-enum-query-type into lp:drizzle/7.0

Proposed by Stewart Smith
Status: Merged
Approved by: Brian Aker
Approved revision: 2216
Merged at revision: 2217
Proposed branch: lp:~stewart/drizzle/remove-enum-query-type
Merge into: lp:drizzle/7.0
Diff against target: 2265 lines (+262/-302)
90 files modified
drizzled/enum.h (+0/-28)
drizzled/function/bit.h (+2/-2)
drizzled/function/bit/functions.h (+2/-2)
drizzled/function/cast/boolean.cc (+2/-2)
drizzled/function/cast/boolean.h (+1/-1)
drizzled/function/cast/signed.cc (+2/-2)
drizzled/function/cast/signed.h (+1/-1)
drizzled/function/cast/unsigned.cc (+2/-2)
drizzled/function/cast/unsigned.h (+1/-1)
drizzled/function/func.cc (+7/-7)
drizzled/function/func.h (+3/-3)
drizzled/function/get_user_var.cc (+1/-2)
drizzled/function/get_user_var.h (+1/-1)
drizzled/function/locate.cc (+4/-4)
drizzled/function/locate.h (+1/-1)
drizzled/function/math/decimal_typecast.cc (+2/-2)
drizzled/function/math/decimal_typecast.h (+1/-1)
drizzled/function/math/int_divide.h (+2/-2)
drizzled/function/num_op.h (+2/-2)
drizzled/function/set_user_var.cc (+2/-2)
drizzled/function/set_user_var.h (+1/-1)
drizzled/function/str/binary.cc (+2/-2)
drizzled/function/str/binary.h (+1/-1)
drizzled/function/str/conv_charset.cc (+2/-2)
drizzled/function/str/conv_charset.h (+1/-1)
drizzled/function/str/make_set.cc (+3/-3)
drizzled/function/str/make_set.h (+1/-1)
drizzled/function/str/set_collation.cc (+2/-2)
drizzled/function/str/set_collation.h (+1/-1)
drizzled/function/str/trim.cc (+4/-4)
drizzled/function/str/trim.h (+1/-1)
drizzled/function/time/date_add_interval.cc (+3/-3)
drizzled/function/time/date_add_interval.h (+1/-1)
drizzled/function/time/extract.cc (+2/-2)
drizzled/function/time/extract.h (+1/-1)
drizzled/function/time/timestamp_diff.cc (+2/-2)
drizzled/function/time/timestamp_diff.h (+1/-1)
drizzled/function/time/typecast.cc (+4/-4)
drizzled/function/time/typecast.h (+2/-2)
drizzled/function/user_var_as_out_param.cc (+1/-2)
drizzled/function/user_var_as_out_param.h (+1/-1)
drizzled/item.cc (+6/-6)
drizzled/item.h (+2/-2)
drizzled/item/cache.cc (+3/-3)
drizzled/item/cache.h (+1/-1)
drizzled/item/cmpfunc.cc (+28/-28)
drizzled/item/cmpfunc.h (+15/-15)
drizzled/item/decimal.cc (+1/-1)
drizzled/item/decimal.h (+1/-1)
drizzled/item/default_value.cc (+2/-2)
drizzled/item/default_value.h (+1/-1)
drizzled/item/field.cc (+2/-2)
drizzled/item/field.h (+1/-1)
drizzled/item/float.cc (+1/-1)
drizzled/item/float.h (+2/-2)
drizzled/item/hex_string.cc (+1/-1)
drizzled/item/hex_string.h (+1/-1)
drizzled/item/ident.cc (+1/-2)
drizzled/item/ident.h (+1/-1)
drizzled/item/insert_value.cc (+2/-2)
drizzled/item/insert_value.h (+1/-1)
drizzled/item/int.cc (+1/-1)
drizzled/item/int.h (+1/-1)
drizzled/item/null.cc (+1/-1)
drizzled/item/null.h (+1/-1)
drizzled/item/ref.cc (+3/-3)
drizzled/item/ref.h (+1/-1)
drizzled/item/ref_null_helper.cc (+2/-2)
drizzled/item/ref_null_helper.h (+1/-1)
drizzled/item/row.cc (+2/-2)
drizzled/item/row.h (+1/-1)
drizzled/item/string.cc (+2/-2)
drizzled/item/string.h (+2/-2)
drizzled/item/subselect.cc (+34/-37)
drizzled/item/subselect.h (+11/-11)
drizzled/item/sum.cc (+5/-5)
drizzled/item/sum.h (+2/-2)
drizzled/item/uint.cc (+1/-1)
drizzled/item/uint.h (+1/-1)
drizzled/sql_lex.cc (+9/-12)
drizzled/sql_lex.h (+5/-6)
drizzled/sql_parse.cc (+1/-1)
drizzled/sql_select.cc (+12/-13)
drizzled/sql_select.h (+1/-2)
drizzled/table_list.cc (+3/-3)
drizzled/table_list.h (+1/-1)
plugin/benchmark/benchmarkudf.cc (+4/-4)
plugin/string_functions/format.cc (+3/-3)
plugin/string_functions/format.h (+1/-1)
plugin/utility_functions/assert.cc (+1/-1)
To merge this branch: bzr merge lp:~stewart/drizzle/remove-enum-query-type
Reviewer Review Type Date Requested Status
Drizzle Developers Pending
Review via email: mp+52016@code.launchpad.net

Description of the change

spotted enum_query_type in drizzled/enum.h which turns out to be completely unused, but passed around everywhere.

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'drizzled/enum.h'
2--- drizzled/enum.h 2011-01-21 01:09:12 +0000
3+++ drizzled/enum.h 2011-03-03 08:34:04 +0000
4@@ -25,34 +25,6 @@
5 {
6
7 /**
8- Query type constants.
9-
10- QT_ORDINARY -- ordinary SQL query.
11- QT_IS -- SQL query to be shown in INFORMATION_SCHEMA (in utf8 and without
12- character set introducers).
13-
14- @TODO
15-
16- Move this out of here once Stew's done with UDF breakout. The following headers need it:
17-
18- sql_lex.h --> included by session.h
19- item.h
20- table.h
21- item_func.h
22- item_subselect.h
23- item_timefunc.h
24- item_sum.h
25- item_cmpfunc.h
26- item_strfunc.h
27-*/
28-enum enum_query_type
29-{
30- QT_ORDINARY,
31- QT_IS
32-};
33-
34-
35-/**
36 * @TODO Move to a separate header?
37 *
38 * It's needed by item.h and field.h, which are both inter-dependent
39
40=== modified file 'drizzled/function/bit.h'
41--- drizzled/function/bit.h 2011-02-23 23:48:30 +0000
42+++ drizzled/function/bit.h 2011-03-03 08:34:04 +0000
43@@ -49,9 +49,9 @@
44
45 void fix_length_and_dec() { unsigned_flag= 1; }
46
47- virtual void print(String *str, enum_query_type query_type)
48+ virtual void print(String *str)
49 {
50- print_op(str, query_type);
51+ print_op(str);
52 }
53 };
54
55
56=== modified file 'drizzled/function/bit/functions.h'
57--- drizzled/function/bit/functions.h 2011-02-23 23:48:30 +0000
58+++ drizzled/function/bit/functions.h 2011-03-03 08:34:04 +0000
59@@ -71,9 +71,9 @@
60 int64_t val_int();
61 const char *func_name() const { return "~"; }
62
63- virtual inline void print(String *str, enum_query_type query_type)
64+ virtual inline void print(String *str)
65 {
66- Item_func::print(str, query_type);
67+ Item_func::print(str);
68 }
69 };
70
71
72=== modified file 'drizzled/function/cast/boolean.cc'
73--- drizzled/function/cast/boolean.cc 2011-02-17 00:14:13 +0000
74+++ drizzled/function/cast/boolean.cc 2011-03-03 08:34:04 +0000
75@@ -29,10 +29,10 @@
76 namespace function {
77 namespace cast {
78
79-void Boolean::print(String *str, enum_query_type query_type)
80+void Boolean::print(String *str)
81 {
82 str->append(STRING_WITH_LEN("cast("));
83- args[0]->print(str, query_type);
84+ args[0]->print(str);
85 str->append(STRING_WITH_LEN(" as boolean)"));
86 }
87
88
89=== modified file 'drizzled/function/cast/boolean.h'
90--- drizzled/function/cast/boolean.h 2011-02-11 21:34:53 +0000
91+++ drizzled/function/cast/boolean.h 2011-03-03 08:34:04 +0000
92@@ -42,7 +42,7 @@
93 collation.set(&my_charset_bin);
94 max_length=args[0]->max_length;
95 }
96- virtual void print(String *str, enum_query_type query_type);
97+ virtual void print(String *str);
98 const char *func_name() const { return "cast_as_boolean"; }
99
100 private:
101
102=== modified file 'drizzled/function/cast/signed.cc'
103--- drizzled/function/cast/signed.cc 2011-02-17 00:14:13 +0000
104+++ drizzled/function/cast/signed.cc 2011-03-03 08:34:04 +0000
105@@ -29,10 +29,10 @@
106 namespace function {
107 namespace cast {
108
109-void Signed::print(String *str, enum_query_type query_type)
110+void Signed::print(String *str)
111 {
112 str->append(STRING_WITH_LEN("cast("));
113- args[0]->print(str, query_type);
114+ args[0]->print(str);
115 str->append(STRING_WITH_LEN(" as signed)"));
116
117 }
118
119=== modified file 'drizzled/function/cast/signed.h'
120--- drizzled/function/cast/signed.h 2011-02-17 00:14:13 +0000
121+++ drizzled/function/cast/signed.h 2011-03-03 08:34:04 +0000
122@@ -44,7 +44,7 @@
123 unsigned_flag= false;
124 }
125
126- void print(String *str, enum_query_type query_type);
127+ void print(String *str);
128
129 uint32_t decimal_precision() const
130 {
131
132=== modified file 'drizzled/function/cast/unsigned.cc'
133--- drizzled/function/cast/unsigned.cc 2011-02-17 00:14:13 +0000
134+++ drizzled/function/cast/unsigned.cc 2011-03-03 08:34:04 +0000
135@@ -29,10 +29,10 @@
136 namespace function {
137 namespace cast {
138
139-void Unsigned::print(String *str, enum_query_type query_type)
140+void Unsigned::print(String *str)
141 {
142 str->append(STRING_WITH_LEN("cast("));
143- args[0]->print(str, query_type);
144+ args[0]->print(str);
145 str->append(STRING_WITH_LEN(" as unsigned)"));
146
147 }
148
149=== modified file 'drizzled/function/cast/unsigned.h'
150--- drizzled/function/cast/unsigned.h 2011-02-17 00:14:13 +0000
151+++ drizzled/function/cast/unsigned.h 2011-03-03 08:34:04 +0000
152@@ -44,7 +44,7 @@
153 unsigned_flag= true;
154 }
155
156- void print(String *str, enum_query_type query_type);
157+ void print(String *str);
158
159 uint32_t decimal_precision() const
160 {
161
162=== modified file 'drizzled/function/func.cc'
163--- drizzled/function/func.cc 2011-02-24 12:11:50 +0000
164+++ drizzled/function/func.cc 2011-03-03 08:34:04 +0000
165@@ -448,37 +448,37 @@
166 }
167
168
169-void Item_func::print(String *str, enum_query_type query_type)
170+void Item_func::print(String *str)
171 {
172 str->append(func_name());
173 str->append('(');
174- print_args(str, 0, query_type);
175+ print_args(str, 0);
176 str->append(')');
177 }
178
179
180-void Item_func::print_args(String *str, uint32_t from, enum_query_type query_type)
181+void Item_func::print_args(String *str, uint32_t from)
182 {
183 for (uint32_t i=from ; i < arg_count ; i++)
184 {
185 if (i != from)
186 str->append(',');
187- args[i]->print(str, query_type);
188+ args[i]->print(str);
189 }
190 }
191
192
193-void Item_func::print_op(String *str, enum_query_type query_type)
194+void Item_func::print_op(String *str)
195 {
196 str->append('(');
197 for (uint32_t i=0 ; i < arg_count-1 ; i++)
198 {
199- args[i]->print(str, query_type);
200+ args[i]->print(str);
201 str->append(' ');
202 str->append(func_name());
203 str->append(' ');
204 }
205- args[arg_count-1]->print(str, query_type);
206+ args[arg_count-1]->print(str);
207 str->append(')');
208 }
209
210
211=== modified file 'drizzled/function/func.h'
212--- drizzled/function/func.h 2011-02-17 00:14:13 +0000
213+++ drizzled/function/func.h 2011-03-03 08:34:04 +0000
214@@ -124,9 +124,9 @@
215 virtual void split_sum_func(Session *session, Item **ref_pointer_array,
216 List<Item> &fields);
217
218- virtual void print(String *str, enum_query_type query_type);
219- void print_op(String *str, enum_query_type query_type);
220- void print_args(String *str, uint32_t from, enum_query_type query_type);
221+ virtual void print(String *str);
222+ void print_op(String *str);
223+ void print_args(String *str, uint32_t from);
224 virtual void fix_num_length_and_dec();
225 void count_only_length();
226 void count_real_length();
227
228=== modified file 'drizzled/function/get_user_var.cc'
229--- drizzled/function/get_user_var.cc 2011-02-17 00:14:13 +0000
230+++ drizzled/function/get_user_var.cc 2011-03-03 08:34:04 +0000
231@@ -130,8 +130,7 @@
232 }
233
234
235-void Item_func_get_user_var::print(String *str,
236- enum_query_type )
237+void Item_func_get_user_var::print(String *str)
238 {
239 str->append(STRING_WITH_LEN("(@"));
240 str->append(name.str,name.length);
241
242=== modified file 'drizzled/function/get_user_var.h'
243--- drizzled/function/get_user_var.h 2011-02-11 21:34:53 +0000
244+++ drizzled/function/get_user_var.h 2011-03-03 08:34:04 +0000
245@@ -49,7 +49,7 @@
246 type::Decimal *val_decimal(type::Decimal*);
247 String *val_str(String* str);
248 void fix_length_and_dec();
249- virtual void print(String *str, enum_query_type query_type);
250+ virtual void print(String *str);
251 enum Item_result result_type() const;
252 /*
253 We must always return variables as strings to guard against selects of type
254
255=== modified file 'drizzled/function/locate.cc'
256--- drizzled/function/locate.cc 2011-02-17 00:14:13 +0000
257+++ drizzled/function/locate.cc 2011-03-03 08:34:04 +0000
258@@ -74,16 +74,16 @@
259 }
260
261
262-void Item_func_locate::print(String *str, enum_query_type query_type)
263+void Item_func_locate::print(String *str)
264 {
265 str->append(STRING_WITH_LEN("locate("));
266- args[1]->print(str, query_type);
267+ args[1]->print(str);
268 str->append(',');
269- args[0]->print(str, query_type);
270+ args[0]->print(str);
271 if (arg_count == 3)
272 {
273 str->append(',');
274- args[2]->print(str, query_type);
275+ args[2]->print(str);
276 }
277 str->append(')');
278 }
279
280=== modified file 'drizzled/function/locate.h'
281--- drizzled/function/locate.h 2010-12-18 04:43:40 +0000
282+++ drizzled/function/locate.h 2011-03-03 08:34:04 +0000
283@@ -36,7 +36,7 @@
284 const char *func_name() const { return "locate"; }
285 int64_t val_int();
286 void fix_length_and_dec();
287- virtual void print(String *str, enum_query_type query_type);
288+ virtual void print(String *str);
289 };
290
291 } /* namespace drizzled */
292
293=== modified file 'drizzled/function/math/decimal_typecast.cc'
294--- drizzled/function/math/decimal_typecast.cc 2011-02-17 00:14:13 +0000
295+++ drizzled/function/math/decimal_typecast.cc 2011-03-03 08:34:04 +0000
296@@ -97,7 +97,7 @@
297 }
298
299
300-void Item_decimal_typecast::print(String *str, enum_query_type query_type)
301+void Item_decimal_typecast::print(String *str)
302 {
303 char len_buf[20*3 + 1];
304 char *end;
305@@ -105,7 +105,7 @@
306 uint32_t precision= class_decimal_length_to_precision(max_length, decimals,
307 unsigned_flag);
308 str->append(STRING_WITH_LEN("cast("));
309- args[0]->print(str, query_type);
310+ args[0]->print(str);
311 str->append(STRING_WITH_LEN(" as decimal("));
312
313 end=internal::int10_to_str(precision, len_buf,10);
314
315=== modified file 'drizzled/function/math/decimal_typecast.h'
316--- drizzled/function/math/decimal_typecast.h 2011-02-11 21:34:53 +0000
317+++ drizzled/function/math/decimal_typecast.h 2011-03-03 08:34:04 +0000
318@@ -43,7 +43,7 @@
319 enum_field_types field_type() const { return DRIZZLE_TYPE_DECIMAL; }
320 void fix_length_and_dec() {};
321 const char *func_name() const { return "decimal_typecast"; }
322- virtual void print(String *str, enum_query_type query_type);
323+ virtual void print(String *str);
324 };
325
326 } /* namespace drizzled */
327
328=== modified file 'drizzled/function/math/int_divide.h'
329--- drizzled/function/math/int_divide.h 2010-12-18 04:43:40 +0000
330+++ drizzled/function/math/int_divide.h 2011-03-03 08:34:04 +0000
331@@ -35,9 +35,9 @@
332 const char *func_name() const { return "DIV"; }
333 void fix_length_and_dec();
334
335- virtual inline void print(String *str, enum_query_type query_type)
336+ virtual inline void print(String *str)
337 {
338- print_op(str, query_type);
339+ print_op(str);
340 }
341
342 };
343
344=== modified file 'drizzled/function/num_op.h'
345--- drizzled/function/num_op.h 2010-12-18 04:43:40 +0000
346+++ drizzled/function/num_op.h 2011-03-03 08:34:04 +0000
347@@ -33,9 +33,9 @@
348 Item_num_op(Item *a,Item *b) :Item_func_numhybrid(a, b) {}
349 virtual void result_precision()= 0;
350
351- virtual inline void print(String *str, enum_query_type query_type)
352+ virtual inline void print(String *str)
353 {
354- print_op(str, query_type);
355+ print_op(str);
356 }
357
358 void find_num_type();
359
360=== modified file 'drizzled/function/set_user_var.cc'
361--- drizzled/function/set_user_var.cc 2011-02-17 00:14:13 +0000
362+++ drizzled/function/set_user_var.cc 2011-03-03 08:34:04 +0000
363@@ -312,12 +312,12 @@
364 return entry->val_decimal(&null_value, val);
365 }
366
367-void Item_func_set_user_var::print(String *str, enum_query_type query_type)
368+void Item_func_set_user_var::print(String *str)
369 {
370 str->append(STRING_WITH_LEN("(@"));
371 str->append(name.str, name.length);
372 str->append(STRING_WITH_LEN(":="));
373- args[0]->print(str, query_type);
374+ args[0]->print(str);
375 str->append(')');
376 }
377
378
379=== modified file 'drizzled/function/set_user_var.h'
380--- drizzled/function/set_user_var.h 2010-12-25 01:27:46 +0000
381+++ drizzled/function/set_user_var.h 2011-03-03 08:34:04 +0000
382@@ -68,7 +68,7 @@
383 enum Item_result result_type () const { return cached_result_type; }
384 bool fix_fields(Session *session, Item **ref);
385 void fix_length_and_dec();
386- virtual void print(String *str, enum_query_type query_type);
387+ virtual void print(String *str);
388
389 const char *func_name() const { return "set_user_var"; }
390 int save_in_field(Field *field, bool no_conversions,
391
392=== modified file 'drizzled/function/str/binary.cc'
393--- drizzled/function/str/binary.cc 2011-02-17 00:14:13 +0000
394+++ drizzled/function/str/binary.cc 2011-03-03 08:34:04 +0000
395@@ -24,10 +24,10 @@
396 namespace drizzled
397 {
398
399-void Item_func_binary::print(String *str, enum_query_type query_type)
400+void Item_func_binary::print(String *str)
401 {
402 str->append(STRING_WITH_LEN("cast("));
403- args[0]->print(str, query_type);
404+ args[0]->print(str);
405 str->append(STRING_WITH_LEN(" as binary)"));
406 }
407
408
409=== modified file 'drizzled/function/str/binary.h'
410--- drizzled/function/str/binary.h 2010-12-18 04:43:40 +0000
411+++ drizzled/function/str/binary.h 2011-03-03 08:34:04 +0000
412@@ -43,7 +43,7 @@
413 collation.set(&my_charset_bin);
414 max_length=args[0]->max_length;
415 }
416- virtual void print(String *str, enum_query_type query_type);
417+ virtual void print(String *str);
418 const char *func_name() const { return "cast_as_binary"; }
419 };
420
421
422=== modified file 'drizzled/function/str/conv_charset.cc'
423--- drizzled/function/str/conv_charset.cc 2011-02-17 00:14:13 +0000
424+++ drizzled/function/str/conv_charset.cc 2011-03-03 08:34:04 +0000
425@@ -47,10 +47,10 @@
426 max_length = args[0]->max_length*conv_charset->mbmaxlen;
427 }
428
429-void Item_func_conv_charset::print(String *str, enum_query_type query_type)
430+void Item_func_conv_charset::print(String *str)
431 {
432 str->append(STRING_WITH_LEN("convert("));
433- args[0]->print(str, query_type);
434+ args[0]->print(str);
435 str->append(STRING_WITH_LEN(" using "));
436 str->append(conv_charset->csname);
437 str->append(')');
438
439=== modified file 'drizzled/function/str/conv_charset.h'
440--- drizzled/function/str/conv_charset.h 2010-12-18 04:43:40 +0000
441+++ drizzled/function/str/conv_charset.h 2011-03-03 08:34:04 +0000
442@@ -65,7 +65,7 @@
443 String *val_str(String *);
444 void fix_length_and_dec();
445 const char *func_name() const { return "convert"; }
446- virtual void print(String *str, enum_query_type query_type);
447+ virtual void print(String *str);
448 };
449
450 } /* namespace drizzled */
451
452=== modified file 'drizzled/function/str/make_set.cc'
453--- drizzled/function/str/make_set.cc 2011-02-24 12:11:50 +0000
454+++ drizzled/function/str/make_set.cc 2011-03-03 08:34:04 +0000
455@@ -121,14 +121,14 @@
456 }
457
458
459-void Item_func_make_set::print(String *str, enum_query_type query_type)
460+void Item_func_make_set::print(String *str)
461 {
462 str->append(STRING_WITH_LEN("make_set("));
463- item->print(str, query_type);
464+ item->print(str);
465 if (arg_count)
466 {
467 str->append(',');
468- print_args(str, 0, query_type);
469+ print_args(str, 0);
470 }
471 str->append(')');
472 }
473
474=== modified file 'drizzled/function/str/make_set.h'
475--- drizzled/function/str/make_set.h 2010-12-18 04:43:40 +0000
476+++ drizzled/function/str/make_set.h 2011-03-03 08:34:04 +0000
477@@ -56,7 +56,7 @@
478 Item_str_func::walk(processor, walk_subquery, arg);
479 }
480 Item *transform(Item_transformer transformer, unsigned char *arg);
481- virtual void print(String *str, enum_query_type query_type);
482+ virtual void print(String *str);
483 };
484
485 } /* namespace drizzled */
486
487=== modified file 'drizzled/function/str/set_collation.cc'
488--- drizzled/function/str/set_collation.cc 2011-02-17 00:14:13 +0000
489+++ drizzled/function/str/set_collation.cc 2011-03-03 08:34:04 +0000
490@@ -85,10 +85,10 @@
491 return 1;
492 }
493
494-void Item_func_set_collation::print(String *str, enum_query_type query_type)
495+void Item_func_set_collation::print(String *str)
496 {
497 str->append('(');
498- args[0]->print(str, query_type);
499+ args[0]->print(str);
500 str->append(STRING_WITH_LEN(" collate "));
501 assert(args[1]->basic_const_item() &&
502 args[1]->type() == Item::STRING_ITEM);
503
504=== modified file 'drizzled/function/str/set_collation.h'
505--- drizzled/function/str/set_collation.h 2010-12-18 04:43:40 +0000
506+++ drizzled/function/str/set_collation.h 2011-03-03 08:34:04 +0000
507@@ -34,7 +34,7 @@
508 bool eq(const Item *item, bool binary_cmp) const;
509 const char *func_name() const { return "collate"; }
510 enum Functype functype() const { return COLLATE_FUNC; }
511- virtual void print(String *str, enum_query_type query_type);
512+ virtual void print(String *str);
513 };
514
515 } /* namespace drizzled */
516
517=== modified file 'drizzled/function/str/trim.cc'
518--- drizzled/function/str/trim.cc 2011-02-21 21:45:55 +0000
519+++ drizzled/function/str/trim.cc 2011-03-03 08:34:04 +0000
520@@ -220,20 +220,20 @@
521 }
522 }
523
524-void Item_func_trim::print(String *str, enum_query_type query_type)
525+void Item_func_trim::print(String *str)
526 {
527 if (arg_count == 1)
528 {
529- Item_func::print(str, query_type);
530+ Item_func::print(str);
531 return;
532 }
533 str->append(Item_func_trim::func_name());
534 str->append('(');
535 str->append(mode_name());
536 str->append(' ');
537- args[1]->print(str, query_type);
538+ args[1]->print(str);
539 str->append(STRING_WITH_LEN(" from "));
540- args[0]->print(str, query_type);
541+ args[0]->print(str);
542 str->append(')');
543 }
544
545
546=== modified file 'drizzled/function/str/trim.h'
547--- drizzled/function/str/trim.h 2010-12-18 04:43:40 +0000
548+++ drizzled/function/str/trim.h 2011-03-03 08:34:04 +0000
549@@ -36,7 +36,7 @@
550 String *val_str(String *);
551 void fix_length_and_dec();
552 const char *func_name() const { return "trim"; }
553- virtual void print(String *str, enum_query_type query_type);
554+ virtual void print(String *str);
555 virtual const char *mode_name() const { return "both"; }
556 };
557
558
559=== modified file 'drizzled/function/time/date_add_interval.cc'
560--- drizzled/function/time/date_add_interval.cc 2011-02-17 00:14:13 +0000
561+++ drizzled/function/time/date_add_interval.cc 2011-03-03 08:34:04 +0000
562@@ -154,12 +154,12 @@
563 (date_sub_interval == other->date_sub_interval));
564 }
565
566-void Item_date_add_interval::print(String *str, enum_query_type query_type)
567+void Item_date_add_interval::print(String *str)
568 {
569 str->append('(');
570- args[0]->print(str, query_type);
571+ args[0]->print(str);
572 str->append(date_sub_interval?" - interval ":" + interval ");
573- args[1]->print(str, query_type);
574+ args[1]->print(str);
575 str->append(' ');
576 str->append(interval_names[int_type]);
577 str->append(')');
578
579=== modified file 'drizzled/function/time/date_add_interval.h'
580--- drizzled/function/time/date_add_interval.h 2011-01-25 05:20:15 +0000
581+++ drizzled/function/time/date_add_interval.h 2011-03-03 08:34:04 +0000
582@@ -42,7 +42,7 @@
583 int64_t val_int();
584 bool get_date(type::Time &res, uint32_t fuzzy_date);
585 bool eq(const Item *item, bool binary_cmp) const;
586- virtual void print(String *str, enum_query_type query_type);
587+ virtual void print(String *str);
588 };
589
590 } /* namespace drizzled */
591
592=== modified file 'drizzled/function/time/extract.cc'
593--- drizzled/function/time/extract.cc 2011-02-17 00:14:13 +0000
594+++ drizzled/function/time/extract.cc 2011-03-03 08:34:04 +0000
595@@ -35,12 +35,12 @@
596
597 extern const char *interval_names[];
598
599-void Item_extract::print(String *str, enum_query_type query_type)
600+void Item_extract::print(String *str)
601 {
602 str->append(STRING_WITH_LEN("extract("));
603 str->append(interval_names[int_type]);
604 str->append(STRING_WITH_LEN(" from "));
605- args[0]->print(str, query_type);
606+ args[0]->print(str);
607 str->append(')');
608 }
609
610
611=== modified file 'drizzled/function/time/extract.h'
612--- drizzled/function/time/extract.h 2010-12-18 04:43:40 +0000
613+++ drizzled/function/time/extract.h 2011-03-03 08:34:04 +0000
614@@ -38,7 +38,7 @@
615 const char *func_name() const { return "extract"; }
616 void fix_length_and_dec();
617 bool eq(const Item *item, bool binary_cmp) const;
618- virtual void print(String *str, enum_query_type query_type);
619+ virtual void print(String *str);
620 };
621
622 } /* namespace drizzled */
623
624=== modified file 'drizzled/function/time/timestamp_diff.cc'
625--- drizzled/function/time/timestamp_diff.cc 2011-02-17 00:14:13 +0000
626+++ drizzled/function/time/timestamp_diff.cc 2011-03-03 08:34:04 +0000
627@@ -130,7 +130,7 @@
628 }
629
630
631-void Item_func_timestamp_diff::print(String *str, enum_query_type query_type)
632+void Item_func_timestamp_diff::print(String *str)
633 {
634 str->append(func_name());
635 str->append('(');
636@@ -170,7 +170,7 @@
637 for (uint32_t i=0 ; i < 2 ; i++)
638 {
639 str->append(',');
640- args[i]->print(str, query_type);
641+ args[i]->print(str);
642 }
643 str->append(')');
644 }
645
646=== modified file 'drizzled/function/time/timestamp_diff.h'
647--- drizzled/function/time/timestamp_diff.h 2010-12-18 04:43:40 +0000
648+++ drizzled/function/time/timestamp_diff.h 2011-03-03 08:34:04 +0000
649@@ -38,7 +38,7 @@
650 decimals=0;
651 maybe_null=1;
652 }
653- virtual void print(String *str, enum_query_type query_type);
654+ virtual void print(String *str);
655 };
656
657 } /* namespace drizzled */
658
659=== modified file 'drizzled/function/time/typecast.cc'
660--- drizzled/function/time/typecast.cc 2011-02-17 00:14:13 +0000
661+++ drizzled/function/time/typecast.cc 2011-03-03 08:34:04 +0000
662@@ -48,20 +48,20 @@
663 return 1;
664 }
665
666-void Item_typecast::print(String *str, enum_query_type query_type)
667+void Item_typecast::print(String *str)
668 {
669 str->append(STRING_WITH_LEN("cast("));
670- args[0]->print(str, query_type);
671+ args[0]->print(str);
672 str->append(STRING_WITH_LEN(" as "));
673 str->append(cast_type());
674 str->append(')');
675 }
676
677
678-void Item_char_typecast::print(String *str, enum_query_type query_type)
679+void Item_char_typecast::print(String *str)
680 {
681 str->append(STRING_WITH_LEN("cast("));
682- args[0]->print(str, query_type);
683+ args[0]->print(str);
684 str->append(STRING_WITH_LEN(" as char"));
685 if (cast_length >= 0)
686 {
687
688=== modified file 'drizzled/function/time/typecast.h'
689--- drizzled/function/time/typecast.h 2011-02-11 21:34:53 +0000
690+++ drizzled/function/time/typecast.h 2011-03-03 08:34:04 +0000
691@@ -49,7 +49,7 @@
692 max_length=args[0]->max_length;
693 }
694 virtual const char* cast_type() const= 0;
695- virtual void print(String *str, enum_query_type query_type);
696+ virtual void print(String *str);
697 };
698
699 class Item_typecast_maybe_null :public Item_typecast
700@@ -81,7 +81,7 @@
701 const char* cast_type() const { return "char"; }
702 String *val_str(String *a);
703 void fix_length_and_dec();
704- virtual void print(String *str, enum_query_type query_type);
705+ virtual void print(String *str);
706 };
707
708 class Item_date_typecast :public Item_typecast_maybe_null
709
710=== modified file 'drizzled/function/user_var_as_out_param.cc'
711--- drizzled/function/user_var_as_out_param.cc 2011-02-17 00:14:13 +0000
712+++ drizzled/function/user_var_as_out_param.cc 2011-03-03 08:34:04 +0000
713@@ -86,8 +86,7 @@
714 }
715
716
717-void Item_user_var_as_out_param::print(String *str,
718- enum_query_type )
719+void Item_user_var_as_out_param::print(String *str)
720 {
721 str->append('@');
722 str->append(name.str,name.length);
723
724=== modified file 'drizzled/function/user_var_as_out_param.h'
725--- drizzled/function/user_var_as_out_param.h 2010-12-25 01:27:46 +0000
726+++ drizzled/function/user_var_as_out_param.h 2011-03-03 08:34:04 +0000
727@@ -48,7 +48,7 @@
728 type::Decimal *val_decimal(type::Decimal *decimal_buffer);
729 /* fix_fields() binds variable name with its entry structure */
730 bool fix_fields(Session *session, Item **ref);
731- virtual void print(String *str, enum_query_type query_type);
732+ virtual void print(String *str);
733 void set_null_value(const CHARSET_INFO * const cs);
734 void set_value(const char *str, uint32_t length, const CHARSET_INFO * const cs);
735 };
736
737=== modified file 'drizzled/item.cc'
738--- drizzled/item.cc 2011-02-28 21:18:08 +0000
739+++ drizzled/item.cc 2011-03-03 08:34:04 +0000
740@@ -362,14 +362,14 @@
741 return class_decimal_int_part(decimal_precision(), decimals);
742 }
743
744-void Item::print(String *str, enum_query_type)
745+void Item::print(String *str)
746 {
747 str->append(full_name());
748 }
749
750-void Item::print_item_w_name(String *str, enum_query_type query_type)
751+void Item::print_item_w_name(String *str)
752 {
753- print(str, query_type);
754+ print(str);
755
756 if (name)
757 {
758@@ -740,12 +740,12 @@
759 const char *table_name_arg, const char *field_name_arg)
760 :Item_ref(context_arg, item, table_name_arg, field_name_arg) {}
761
762- virtual inline void print (String *str, enum_query_type query_type)
763+ virtual inline void print (String *str)
764 {
765 if (ref)
766- (*ref)->print(str, query_type);
767+ (*ref)->print(str);
768 else
769- Item_ident::print(str, query_type);
770+ Item_ident::print(str);
771 }
772 };
773
774
775=== modified file 'drizzled/item.h'
776--- drizzled/item.h 2011-02-22 21:46:00 +0000
777+++ drizzled/item.h 2011-03-03 08:34:04 +0000
778@@ -551,9 +551,9 @@
779 query and why they should be generated from the Item-tree, @see
780 register_view().
781 */
782- virtual void print(String *str, enum_query_type query_type);
783+ virtual void print(String *str);
784
785- void print_item_w_name(String *, enum_query_type query_type);
786+ void print_item_w_name(String *);
787 virtual void update_used_tables() {}
788 virtual void split_sum_func(Session *session,
789 Item **ref_pointer_array,
790
791=== modified file 'drizzled/item/cache.cc'
792--- drizzled/item/cache.cc 2011-02-17 00:14:13 +0000
793+++ drizzled/item/cache.cc 2011-03-03 08:34:04 +0000
794@@ -55,13 +55,13 @@
795 }
796
797
798-void Item_cache::print(String *str, enum_query_type query_type)
799+void Item_cache::print(String *str)
800 {
801 str->append(STRING_WITH_LEN("<cache>("));
802 if (example)
803- example->print(str, query_type);
804+ example->print(str);
805 else
806- Item::print(str, query_type);
807+ Item::print(str);
808 str->append(')');
809 }
810
811
812=== modified file 'drizzled/item/cache.h'
813--- drizzled/item/cache.h 2011-02-11 21:34:53 +0000
814+++ drizzled/item/cache.h 2011-03-03 08:34:04 +0000
815@@ -77,7 +77,7 @@
816 static Item_cache* get_cache(const Item *item);
817 table_map used_tables() const { return used_table_map; }
818 virtual void keep_array() {}
819- virtual void print(String *str, enum_query_type query_type);
820+ virtual void print(String *str);
821 bool eq_def(Field *field);
822 bool eq(const Item *item, bool) const
823 {
824
825=== modified file 'drizzled/item/cmpfunc.cc'
826--- drizzled/item/cmpfunc.cc 2011-02-28 21:18:08 +0000
827+++ drizzled/item/cmpfunc.cc 2011-03-03 08:34:04 +0000
828@@ -347,10 +347,10 @@
829 higher than the precedence of NOT.
830 */
831
832-void Item_func_not::print(String *str, enum_query_type query_type)
833+void Item_func_not::print(String *str)
834 {
835 str->append('(');
836- Item_func::print(str, query_type);
837+ Item_func::print(str);
838 str->append(')');
839 }
840
841@@ -382,12 +382,12 @@
842 (test_sub_item && !test_sub_item->any_value()));
843 }
844
845-void Item_func_not_all::print(String *str, enum_query_type query_type)
846+void Item_func_not_all::print(String *str)
847 {
848 if (show)
849- Item_func::print(str, query_type);
850+ Item_func::print(str);
851 else
852- args[0]->print(str, query_type);
853+ args[0]->print(str);
854 }
855
856
857@@ -1445,10 +1445,10 @@
858 }
859
860
861-void Item_func_truth::print(String *str, enum_query_type query_type)
862+void Item_func_truth::print(String *str)
863 {
864 str->append('(');
865- args[0]->print(str, query_type);
866+ args[0]->print(str);
867 str->append(STRING_WITH_LEN(" is "));
868 if (! affirmative)
869 str->append(STRING_WITH_LEN("not "));
870@@ -2176,16 +2176,16 @@
871 }
872
873
874-void Item_func_between::print(String *str, enum_query_type query_type)
875+void Item_func_between::print(String *str)
876 {
877 str->append('(');
878- args[0]->print(str, query_type);
879+ args[0]->print(str);
880 if (negated)
881 str->append(STRING_WITH_LEN(" not"));
882 str->append(STRING_WITH_LEN(" between "));
883- args[1]->print(str, query_type);
884+ args[1]->print(str);
885 str->append(STRING_WITH_LEN(" and "));
886- args[2]->print(str, query_type);
887+ args[2]->print(str);
888 str->append(')');
889 }
890
891@@ -2834,26 +2834,26 @@
892 Fix this so that it prints the whole CASE expression
893 */
894
895-void Item_func_case::print(String *str, enum_query_type query_type)
896+void Item_func_case::print(String *str)
897 {
898 str->append(STRING_WITH_LEN("(case "));
899 if (first_expr_num != -1)
900 {
901- args[first_expr_num]->print(str, query_type);
902+ args[first_expr_num]->print(str);
903 str->append(' ');
904 }
905 for (uint32_t i=0 ; i < ncases ; i+=2)
906 {
907 str->append(STRING_WITH_LEN("when "));
908- args[i]->print(str, query_type);
909+ args[i]->print(str);
910 str->append(STRING_WITH_LEN(" then "));
911- args[i+1]->print(str, query_type);
912+ args[i+1]->print(str);
913 str->append(' ');
914 }
915 if (else_expr_num != -1)
916 {
917 str->append(STRING_WITH_LEN("else "));
918- args[else_expr_num]->print(str, query_type);
919+ args[else_expr_num]->print(str);
920 str->append(' ');
921 }
922 str->append(STRING_WITH_LEN("end)"));
923@@ -3794,14 +3794,14 @@
924 }
925
926
927-void Item_func_in::print(String *str, enum_query_type query_type)
928+void Item_func_in::print(String *str)
929 {
930 str->append('(');
931- args[0]->print(str, query_type);
932+ args[0]->print(str);
933 if (negated)
934 str->append(STRING_WITH_LEN(" not"));
935 str->append(STRING_WITH_LEN(" in ("));
936- print_args(str, 1, query_type);
937+ print_args(str, 1);
938 str->append(STRING_WITH_LEN("))"));
939 }
940
941@@ -4158,19 +4158,19 @@
942 }
943
944
945-void Item_cond::print(String *str, enum_query_type query_type)
946+void Item_cond::print(String *str)
947 {
948 str->append('(');
949 List<Item>::iterator li(list.begin());
950 Item *item;
951 if ((item=li++))
952- item->print(str, query_type);
953+ item->print(str);
954 while ((item=li++))
955 {
956 str->append(' ');
957 str->append(func_name());
958 str->append(' ');
959- item->print(str, query_type);
960+ item->print(str);
961 }
962 str->append(')');
963 }
964@@ -4350,10 +4350,10 @@
965 }
966
967
968-void Item_func_isnotnull::print(String *str, enum_query_type query_type)
969+void Item_func_isnotnull::print(String *str)
970 {
971 str->append('(');
972- args[0]->print(str, query_type);
973+ args[0]->print(str);
974 str->append(STRING_WITH_LEN(" is not null)"));
975 }
976
977@@ -5166,24 +5166,24 @@
978 return Item_func::transform(transformer, arg);
979 }
980
981-void Item_equal::print(String *str, enum_query_type query_type)
982+void Item_equal::print(String *str)
983 {
984 str->append(func_name());
985 str->append('(');
986 List<Item_field>::iterator it(fields.begin());
987 Item *item;
988 if (const_item)
989- const_item->print(str, query_type);
990+ const_item->print(str);
991 else
992 {
993 item= it++;
994- item->print(str, query_type);
995+ item->print(str);
996 }
997 while ((item= it++))
998 {
999 str->append(',');
1000 str->append(' ');
1001- item->print(str, query_type);
1002+ item->print(str);
1003 }
1004 str->append(')');
1005 }
1006
1007=== modified file 'drizzled/item/cmpfunc.h'
1008--- drizzled/item/cmpfunc.h 2011-02-23 15:52:28 +0000
1009+++ drizzled/item/cmpfunc.h 2011-03-03 08:34:04 +0000
1010@@ -139,7 +139,7 @@
1011 virtual bool val_bool();
1012 virtual int64_t val_int();
1013 virtual void fix_length_and_dec();
1014- virtual void print(String *str, enum_query_type query_type);
1015+ virtual void print(String *str);
1016
1017 protected:
1018 Item_func_truth(Item *a, bool a_value, bool a_affirmative)
1019@@ -351,9 +351,9 @@
1020 virtual enum Functype rev_functype() const { return UNKNOWN_FUNC; }
1021 bool have_rev_func() const { return rev_functype() != UNKNOWN_FUNC; }
1022
1023- virtual inline void print(String *str, enum_query_type query_type)
1024+ virtual inline void print(String *str)
1025 {
1026- Item_func::print_op(str, query_type);
1027+ Item_func::print_op(str);
1028 }
1029
1030 bool is_null() { return test(args[0]->is_null() || args[1]->is_null()); }
1031@@ -386,7 +386,7 @@
1032 enum Functype functype() const { return NOT_FUNC; }
1033 const char *func_name() const { return "not"; }
1034 Item *neg_transformer(Session *session);
1035- virtual void print(String *str, enum_query_type query_type);
1036+ virtual void print(String *str);
1037 };
1038
1039 class Item_maxmin_subselect;
1040@@ -453,7 +453,7 @@
1041 int64_t val_int();
1042 enum Functype functype() const { return NOT_ALL_FUNC; }
1043 const char *func_name() const { return "<not>"; }
1044- virtual void print(String *str, enum_query_type query_type);
1045+ virtual void print(String *str);
1046 void set_sum_test(Item_sum_hybrid *item) { test_sum_item= item; };
1047 void set_sub_test(Item_maxmin_subselect *item) { test_sub_item= item; };
1048 bool empty_underlying_subquery();
1049@@ -615,7 +615,7 @@
1050 const char *func_name() const { return "between"; }
1051 bool fix_fields(Session *, Item **);
1052 void fix_length_and_dec();
1053- virtual void print(String *str, enum_query_type query_type);
1054+ virtual void print(String *str);
1055 bool is_bool_func() { return 1; }
1056 const CHARSET_INFO *compare_collation() { return cmp_collation.collation; }
1057 uint32_t decimal_precision() const { return 1; }
1058@@ -630,9 +630,9 @@
1059 optimize_type select_optimize() const { return OPTIMIZE_NONE; }
1060 const char *func_name() const { return "strcmp"; }
1061
1062- virtual inline void print(String *str, enum_query_type query_type)
1063+ virtual inline void print(String *str)
1064 {
1065- Item_func::print(str, query_type);
1066+ Item_func::print(str);
1067 }
1068 };
1069
1070@@ -741,9 +741,9 @@
1071 uint32_t decimal_precision() const { return args[0]->decimal_precision(); }
1072 const char *func_name() const { return "nullif"; }
1073
1074- virtual inline void print(String *str, enum_query_type query_type)
1075+ virtual inline void print(String *str)
1076 {
1077- Item_func::print(str, query_type);
1078+ Item_func::print(str);
1079 }
1080
1081 table_map not_null_tables() const { return 0; }
1082@@ -1177,7 +1177,7 @@
1083 enum Item_result result_type () const { return cached_result_type; }
1084 enum_field_types field_type() const { return cached_field_type; }
1085 const char *func_name() const { return "case"; }
1086- virtual void print(String *str, enum_query_type query_type);
1087+ virtual void print(String *str);
1088 Item *find_item(String *str);
1089 const CHARSET_INFO *compare_collation() { return cmp_collation.collation; }
1090 void cleanup();
1091@@ -1242,7 +1242,7 @@
1092 }
1093 optimize_type select_optimize() const
1094 { return OPTIMIZE_KEY; }
1095- virtual void print(String *str, enum_query_type query_type);
1096+ virtual void print(String *str);
1097 enum Functype functype() const { return IN_FUNC; }
1098 const char *func_name() const { return " IN "; }
1099 bool nulls_in_row();
1100@@ -1364,7 +1364,7 @@
1101 table_map not_null_tables() const
1102 { return abort_on_null ? not_null_tables_cache : 0; }
1103 Item *neg_transformer(Session *session);
1104- virtual void print(String *str, enum_query_type query_type);
1105+ virtual void print(String *str);
1106 const CHARSET_INFO *compare_collation() { return args[0]->collation.collation; }
1107 void top_level_item() { abort_on_null=1; }
1108 };
1109@@ -1445,7 +1445,7 @@
1110 List<Item>* argument_list() { return &list; }
1111 table_map used_tables() const;
1112 void update_used_tables();
1113- virtual void print(String *str, enum_query_type query_type);
1114+ virtual void print(String *str);
1115 void split_sum_func(Session *session, Item **ref_pointer_array, List<Item> &fields);
1116 friend int setup_conds(Session *session, TableList *tables, TableList *leaves,
1117 COND **conds);
1118@@ -1577,7 +1577,7 @@
1119 void update_used_tables();
1120 bool walk(Item_processor processor, bool walk_subquery, unsigned char *arg);
1121 Item *transform(Item_transformer transformer, unsigned char *arg);
1122- virtual void print(String *str, enum_query_type query_type);
1123+ virtual void print(String *str);
1124 const CHARSET_INFO *compare_collation()
1125 { return fields.front().collation.collation; }
1126 private:
1127
1128=== modified file 'drizzled/item/decimal.cc'
1129--- drizzled/item/decimal.cc 2011-02-17 00:14:13 +0000
1130+++ drizzled/item/decimal.cc 2011-03-03 08:34:04 +0000
1131@@ -108,7 +108,7 @@
1132 return result;
1133 }
1134
1135-void Item_decimal::print(String *str, enum_query_type)
1136+void Item_decimal::print(String *str)
1137 {
1138 class_decimal2string(&decimal_value, 0, &str_value);
1139 str->append(str_value);
1140
1141=== modified file 'drizzled/item/decimal.h'
1142--- drizzled/item/decimal.h 2010-12-25 01:27:46 +0000
1143+++ drizzled/item/decimal.h 2011-03-03 08:34:04 +0000
1144@@ -53,7 +53,7 @@
1145 {
1146 return new Item_decimal(name, &decimal_value, decimals, max_length);
1147 }
1148- virtual void print(String *str, enum_query_type query_type);
1149+ virtual void print(String *str);
1150 Item_num *neg()
1151 {
1152 class_decimal_neg(&decimal_value);
1153
1154=== modified file 'drizzled/item/default_value.cc'
1155--- drizzled/item/default_value.cc 2011-02-24 12:11:50 +0000
1156+++ drizzled/item/default_value.cc 2011-03-03 08:34:04 +0000
1157@@ -78,7 +78,7 @@
1158 }
1159
1160
1161-void Item_default_value::print(String *str, enum_query_type query_type)
1162+void Item_default_value::print(String *str)
1163 {
1164 if (!arg)
1165 {
1166@@ -86,7 +86,7 @@
1167 return;
1168 }
1169 str->append(STRING_WITH_LEN("default("));
1170- arg->print(str, query_type);
1171+ arg->print(str);
1172 str->append(')');
1173 }
1174
1175
1176=== modified file 'drizzled/item/default_value.h'
1177--- drizzled/item/default_value.h 2010-12-18 04:43:40 +0000
1178+++ drizzled/item/default_value.h 2011-03-03 08:34:04 +0000
1179@@ -41,7 +41,7 @@
1180 enum Type type() const { return DEFAULT_VALUE_ITEM; }
1181 bool eq(const Item *item, bool binary_cmp) const;
1182 bool fix_fields(Session *, Item **);
1183- virtual void print(String *str, enum_query_type query_type);
1184+ virtual void print(String *str);
1185 int save_in_field(Field *field_arg, bool no_conversions);
1186 table_map used_tables() const { return (table_map)0L; }
1187
1188
1189=== modified file 'drizzled/item/field.cc'
1190--- drizzled/item/field.cc 2011-02-28 21:18:08 +0000
1191+++ drizzled/item/field.cc 2011-03-03 08:34:04 +0000
1192@@ -1266,7 +1266,7 @@
1193 }
1194
1195
1196-void Item_field::print(String *str, enum_query_type query_type)
1197+void Item_field::print(String *str)
1198 {
1199 if (field && field->getTable()->const_table)
1200 {
1201@@ -1283,7 +1283,7 @@
1202 }
1203 return;
1204 }
1205- Item_ident::print(str, query_type);
1206+ Item_ident::print(str);
1207 }
1208
1209
1210
1211=== modified file 'drizzled/item/field.h'
1212--- drizzled/item/field.h 2011-02-11 21:34:53 +0000
1213+++ drizzled/item/field.h 2011-03-03 08:34:04 +0000
1214@@ -109,7 +109,7 @@
1215 Item *safe_charset_converter(const CHARSET_INFO * const tocs);
1216 int fix_outer_field(Session *session, Field **field, Item **reference);
1217 virtual Item *update_value_transformer(unsigned char *select_arg);
1218- virtual void print(String *str, enum_query_type query_type);
1219+ virtual void print(String *str);
1220
1221 friend class Item_default_value;
1222 friend class Item_insert_value;
1223
1224=== modified file 'drizzled/item/float.cc'
1225--- drizzled/item/float.cc 2011-02-17 00:14:13 +0000
1226+++ drizzled/item/float.cc 2011-03-03 08:34:04 +0000
1227@@ -121,7 +121,7 @@
1228 }
1229
1230
1231-void Item_float::print(String *str, enum_query_type)
1232+void Item_float::print(String *str)
1233 {
1234 if (presentation)
1235 {
1236
1237=== modified file 'drizzled/item/float.h'
1238--- drizzled/item/float.h 2010-12-25 01:27:46 +0000
1239+++ drizzled/item/float.h 2011-03-03 08:34:04 +0000
1240@@ -56,7 +56,7 @@
1241 Item *clone_item()
1242 { return new Item_float(name, value, decimals, max_length); }
1243 Item_num *neg() { value= -value; return this; }
1244- virtual void print(String *str, enum_query_type query_type);
1245+ virtual void print(String *str);
1246 bool eq(const Item *, bool binary_cmp) const;
1247 };
1248
1249@@ -69,7 +69,7 @@
1250 :Item_float(NULL, val_arg, decimal_par, length), func_name(str)
1251 {}
1252
1253- virtual inline void print(String *str, enum_query_type)
1254+ virtual inline void print(String *str)
1255 {
1256 str->append(func_name);
1257 }
1258
1259=== modified file 'drizzled/item/hex_string.cc'
1260--- drizzled/item/hex_string.cc 2011-02-17 00:14:13 +0000
1261+++ drizzled/item/hex_string.cc 2011-03-03 08:34:04 +0000
1262@@ -115,7 +115,7 @@
1263 return 1;
1264 }
1265
1266-void Item_hex_string::print(String *str, enum_query_type)
1267+void Item_hex_string::print(String *str)
1268 {
1269 char *end= (char*) str_value.ptr() + str_value.length(),
1270 *ptr= end - min(str_value.length(), sizeof(int64_t));
1271
1272=== modified file 'drizzled/item/hex_string.h'
1273--- drizzled/item/hex_string.h 2010-12-25 01:27:46 +0000
1274+++ drizzled/item/hex_string.h 2011-03-03 08:34:04 +0000
1275@@ -44,7 +44,7 @@
1276 enum Item_result result_type () const { return STRING_RESULT; }
1277 enum Item_result cast_to_int_type() const { return INT_RESULT; }
1278 enum_field_types field_type() const { return DRIZZLE_TYPE_VARCHAR; }
1279- virtual void print(String *str, enum_query_type query_type);
1280+ virtual void print(String *str);
1281 bool eq(const Item *item, bool binary_cmp) const;
1282 virtual Item *safe_charset_converter(const CHARSET_INFO * const tocs);
1283 };
1284
1285=== modified file 'drizzled/item/ident.cc'
1286--- drizzled/item/ident.cc 2011-02-17 00:14:13 +0000
1287+++ drizzled/item/ident.cc 2011-03-03 08:34:04 +0000
1288@@ -107,8 +107,7 @@
1289 }
1290
1291
1292-void Item_ident::print(String *str,
1293- enum_query_type)
1294+void Item_ident::print(String *str)
1295 {
1296 string d_name, t_name;
1297
1298
1299=== modified file 'drizzled/item/ident.h'
1300--- drizzled/item/ident.h 2011-02-18 12:05:58 +0000
1301+++ drizzled/item/ident.h 2011-03-03 08:34:04 +0000
1302@@ -68,7 +68,7 @@
1303 const char *full_name() const;
1304 void cleanup();
1305 bool remove_dependence_processor(unsigned char * arg);
1306- virtual void print(String *str, enum_query_type query_type);
1307+ virtual void print(String *str);
1308 virtual bool change_context_processor(unsigned char *cntx)
1309 { context= (Name_resolution_context *)cntx; return false; }
1310 friend bool insert_fields(Session *session, Name_resolution_context *context,
1311
1312=== modified file 'drizzled/item/insert_value.cc'
1313--- drizzled/item/insert_value.cc 2011-02-17 00:14:13 +0000
1314+++ drizzled/item/insert_value.cc 2011-03-03 08:34:04 +0000
1315@@ -94,10 +94,10 @@
1316 }
1317
1318
1319-void Item_insert_value::print(String *str, enum_query_type query_type)
1320+void Item_insert_value::print(String *str)
1321 {
1322 str->append(STRING_WITH_LEN("values("));
1323- arg->print(str, query_type);
1324+ arg->print(str);
1325 str->append(')');
1326 }
1327
1328
1329=== modified file 'drizzled/item/insert_value.h'
1330--- drizzled/item/insert_value.h 2011-02-17 00:14:13 +0000
1331+++ drizzled/item/insert_value.h 2011-03-03 08:34:04 +0000
1332@@ -45,7 +45,7 @@
1333 arg(a) {}
1334 bool eq(const Item *item, bool binary_cmp) const;
1335 bool fix_fields(Session *, Item **);
1336- virtual void print(String *str, enum_query_type query_type);
1337+ virtual void print(String *str);
1338 int save_in_field(Field *field_arg, bool no_conversions)
1339 {
1340 return Item_field::save_in_field(field_arg, no_conversions);
1341
1342=== modified file 'drizzled/item/int.cc'
1343--- drizzled/item/int.cc 2011-02-17 00:14:13 +0000
1344+++ drizzled/item/int.cc 2011-03-03 08:34:04 +0000
1345@@ -57,7 +57,7 @@
1346 return str;
1347 }
1348
1349-void Item_int::print(String *str, enum_query_type)
1350+void Item_int::print(String *str)
1351 {
1352 // my_charset_bin is good enough for numbers
1353 str_value.set(value, &my_charset_bin);
1354
1355=== modified file 'drizzled/item/int.h'
1356--- drizzled/item/int.h 2010-12-25 01:27:46 +0000
1357+++ drizzled/item/int.h 2011-03-03 08:34:04 +0000
1358@@ -69,7 +69,7 @@
1359
1360 Item *clone_item() { return new Item_int(name,value,max_length); }
1361
1362- virtual void print(String *str, enum_query_type query_type);
1363+ virtual void print(String *str);
1364
1365 Item_num *neg() { value= -value; return this; }
1366
1367
1368=== modified file 'drizzled/item/null.cc'
1369--- drizzled/item/null.cc 2011-02-17 00:14:13 +0000
1370+++ drizzled/item/null.cc 2011-03-03 08:34:04 +0000
1371@@ -59,7 +59,7 @@
1372 }
1373
1374
1375-void Item_null::print(String *str, enum_query_type)
1376+void Item_null::print(String *str)
1377 {
1378 str->append(STRING_WITH_LEN("NULL"));
1379 }
1380
1381=== modified file 'drizzled/item/null.h'
1382--- drizzled/item/null.h 2011-02-11 21:34:53 +0000
1383+++ drizzled/item/null.h 2011-03-03 08:34:04 +0000
1384@@ -53,7 +53,7 @@
1385 Item *clone_item() { return new Item_null(name); }
1386 bool is_null() { return true; }
1387
1388- virtual void print(String *str, enum_query_type);
1389+ virtual void print(String *str);
1390
1391 Item *safe_charset_converter(const CHARSET_INFO * const tocs);
1392 };
1393
1394=== modified file 'drizzled/item/ref.cc'
1395--- drizzled/item/ref.cc 2011-02-28 21:18:08 +0000
1396+++ drizzled/item/ref.cc 2011-03-03 08:34:04 +0000
1397@@ -369,7 +369,7 @@
1398 }
1399
1400
1401-void Item_ref::print(String *str, enum_query_type query_type)
1402+void Item_ref::print(String *str)
1403 {
1404 if (ref)
1405 {
1406@@ -379,10 +379,10 @@
1407 str->append_identifier(name, (uint32_t) strlen(name));
1408 }
1409 else
1410- (*ref)->print(str, query_type);
1411+ (*ref)->print(str);
1412 }
1413 else
1414- Item_ident::print(str, query_type);
1415+ Item_ident::print(str);
1416 }
1417
1418
1419
1420=== modified file 'drizzled/item/ref.h'
1421--- drizzled/item/ref.h 2011-02-17 00:14:13 +0000
1422+++ drizzled/item/ref.h 2011-03-03 08:34:04 +0000
1423@@ -114,7 +114,7 @@
1424 }
1425 bool walk(Item_processor processor, bool walk_subquery, unsigned char *arg)
1426 { return (*ref)->walk(processor, walk_subquery, arg); }
1427- virtual void print(String *str, enum_query_type query_type);
1428+ virtual void print(String *str);
1429 bool result_as_int64_t()
1430 {
1431 return (*ref)->result_as_int64_t();
1432
1433=== modified file 'drizzled/item/ref_null_helper.cc'
1434--- drizzled/item/ref_null_helper.cc 2011-02-17 00:14:13 +0000
1435+++ drizzled/item/ref_null_helper.cc 2011-03-03 08:34:04 +0000
1436@@ -75,11 +75,11 @@
1437 return (owner->was_null|= null_value= (*ref)->get_date(ltime, fuzzydate));
1438 }
1439
1440-void Item_ref_null_helper::print(String *str, enum_query_type query_type)
1441+void Item_ref_null_helper::print(String *str)
1442 {
1443 str->append(STRING_WITH_LEN("<ref_null_helper>("));
1444 if (ref)
1445- (*ref)->print(str, query_type);
1446+ (*ref)->print(str);
1447 else
1448 str->append('?');
1449 str->append(')');
1450
1451=== modified file 'drizzled/item/ref_null_helper.h'
1452--- drizzled/item/ref_null_helper.h 2011-01-25 05:20:15 +0000
1453+++ drizzled/item/ref_null_helper.h 2011-03-03 08:34:04 +0000
1454@@ -48,7 +48,7 @@
1455 type::Decimal *val_decimal(type::Decimal *);
1456 bool val_bool();
1457 bool get_date(type::Time &ltime, uint32_t fuzzydate);
1458- virtual void print(String *str, enum_query_type query_type);
1459+ virtual void print(String *str);
1460 /*
1461 we add RAND_TABLE_BIT to prevent moving this item from HAVING to WHERE
1462 */
1463
1464=== modified file 'drizzled/item/row.cc'
1465--- drizzled/item/row.cc 2011-02-24 12:11:50 +0000
1466+++ drizzled/item/row.cc 2011-03-03 08:34:04 +0000
1467@@ -149,14 +149,14 @@
1468 return 0;
1469 }
1470
1471-void Item_row::print(String *str, enum_query_type query_type)
1472+void Item_row::print(String *str)
1473 {
1474 str->append('(');
1475 for (uint32_t i= 0; i < arg_count; i++)
1476 {
1477 if (i)
1478 str->append(',');
1479- items[i]->print(str, query_type);
1480+ items[i]->print(str);
1481 }
1482 str->append(')');
1483 }
1484
1485=== modified file 'drizzled/item/row.h'
1486--- drizzled/item/row.h 2011-02-17 00:14:13 +0000
1487+++ drizzled/item/row.h 2011-03-03 08:34:04 +0000
1488@@ -81,7 +81,7 @@
1489 bool const_item() const { return const_item_cache; };
1490 enum Item_result result_type() const { return ROW_RESULT; }
1491 void update_used_tables();
1492- virtual void print(String *str, enum_query_type query_type);
1493+ virtual void print(String *str);
1494
1495 bool walk(Item_processor processor, bool walk_subquery, unsigned char *arg);
1496 Item *transform(Item_transformer transformer, unsigned char *arg);
1497
1498=== modified file 'drizzled/item/string.cc'
1499--- drizzled/item/string.cc 2011-02-17 00:14:13 +0000
1500+++ drizzled/item/string.cc 2011-03-03 08:34:04 +0000
1501@@ -95,9 +95,9 @@
1502 return 0;
1503 }
1504
1505-void Item_string::print(String *str, enum_query_type query_type)
1506+void Item_string::print(String *str)
1507 {
1508- if (query_type == QT_ORDINARY && is_cs_specified())
1509+ if (is_cs_specified())
1510 {
1511 str->append('_');
1512 str->append(collation.collation->csname);
1513
1514=== modified file 'drizzled/item/string.h'
1515--- drizzled/item/string.h 2011-02-11 21:34:53 +0000
1516+++ drizzled/item/string.h 2011-03-03 08:34:04 +0000
1517@@ -95,7 +95,7 @@
1518 str_value.append(str, length);
1519 max_length= str_value.numchars() * collation.collation->mbmaxlen;
1520 }
1521- virtual void print(String *str, enum_query_type query_type);
1522+ virtual void print(String *str);
1523
1524 /**
1525 Return true if character-set-introducer was explicitly specified in the
1526@@ -152,7 +152,7 @@
1527 {}
1528 Item *safe_charset_converter(const CHARSET_INFO * const tocs);
1529
1530- virtual inline void print(String *str, enum_query_type)
1531+ virtual inline void print(String *str)
1532 {
1533 str->append(func_name);
1534 }
1535
1536=== modified file 'drizzled/item/subselect.cc'
1537--- drizzled/item/subselect.cc 2011-02-23 15:52:28 +0000
1538+++ drizzled/item/subselect.cc 2011-03-03 08:34:04 +0000
1539@@ -406,10 +406,10 @@
1540 }
1541
1542
1543-void Item_subselect::print(String *str, enum_query_type query_type)
1544+void Item_subselect::print(String *str)
1545 {
1546 str->append('(');
1547- engine->print(str, query_type);
1548+ engine->print(str);
1549 str->append(')');
1550 }
1551
1552@@ -487,10 +487,10 @@
1553 }
1554
1555
1556-void Item_maxmin_subselect::print(String *str, enum_query_type query_type)
1557+void Item_maxmin_subselect::print(String *str)
1558 {
1559 str->append(max?"<max>":"<min>", 5);
1560- Item_singlerow_subselect::print(str, query_type);
1561+ Item_singlerow_subselect::print(str);
1562 }
1563
1564
1565@@ -718,10 +718,10 @@
1566 }
1567
1568
1569-void Item_exists_subselect::print(String *str, enum_query_type query_type)
1570+void Item_exists_subselect::print(String *str)
1571 {
1572 str->append(STRING_WITH_LEN("exists"));
1573- Item_subselect::print(str, query_type);
1574+ Item_subselect::print(str);
1575 }
1576
1577
1578@@ -1733,16 +1733,16 @@
1579 }
1580
1581
1582-void Item_in_subselect::print(String *str, enum_query_type query_type)
1583+void Item_in_subselect::print(String *str)
1584 {
1585 if (exec_method == IN_TO_EXISTS)
1586 str->append(STRING_WITH_LEN("<exists>"));
1587 else
1588 {
1589- left_expr->print(str, query_type);
1590+ left_expr->print(str);
1591 str->append(STRING_WITH_LEN(" in "));
1592 }
1593- Item_subselect::print(str, query_type);
1594+ Item_subselect::print(str);
1595 }
1596
1597
1598@@ -1905,18 +1905,18 @@
1599 }
1600
1601
1602-void Item_allany_subselect::print(String *str, enum_query_type query_type)
1603+void Item_allany_subselect::print(String *str)
1604 {
1605 if (exec_method == IN_TO_EXISTS)
1606 str->append(STRING_WITH_LEN("<exists>"));
1607 else
1608 {
1609- left_expr->print(str, query_type);
1610+ left_expr->print(str);
1611 str->append(' ');
1612 str->append(func->symbol(all));
1613 str->append(all ? " all " : " any ", 5);
1614 }
1615- Item_subselect::print(str, query_type);
1616+ Item_subselect::print(str);
1617 }
1618
1619
1620@@ -2763,25 +2763,23 @@
1621 }
1622
1623
1624-void subselect_single_select_engine::print(String *str,
1625- enum_query_type query_type)
1626-{
1627- select_lex->print(session, str, query_type);
1628-}
1629-
1630-
1631-void subselect_union_engine::print(String *str, enum_query_type query_type)
1632-{
1633- unit->print(str, query_type);
1634-}
1635-
1636-
1637-void subselect_uniquesubquery_engine::print(String *str,
1638- enum_query_type query_type)
1639+void subselect_single_select_engine::print(String *str)
1640+{
1641+ select_lex->print(session, str);
1642+}
1643+
1644+
1645+void subselect_union_engine::print(String *str)
1646+{
1647+ unit->print(str);
1648+}
1649+
1650+
1651+void subselect_uniquesubquery_engine::print(String *str)
1652 {
1653 const char *table_name= tab->table->getShare()->getTableName();
1654 str->append(STRING_WITH_LEN("<primary_index_lookup>("));
1655- tab->ref.items[0]->print(str, query_type);
1656+ tab->ref.items[0]->print(str);
1657 str->append(STRING_WITH_LEN(" in "));
1658 if (tab->table->getShare()->isTemporaryCategory())
1659 {
1660@@ -2799,7 +2797,7 @@
1661 if (cond)
1662 {
1663 str->append(STRING_WITH_LEN(" where "));
1664- cond->print(str, query_type);
1665+ cond->print(str);
1666 }
1667 str->append(')');
1668 }
1669@@ -2828,11 +2826,10 @@
1670 }
1671 */
1672
1673-void subselect_indexsubquery_engine::print(String *str,
1674- enum_query_type query_type)
1675+void subselect_indexsubquery_engine::print(String *str)
1676 {
1677 str->append(STRING_WITH_LEN("<index_lookup>("));
1678- tab->ref.items[0]->print(str, query_type);
1679+ tab->ref.items[0]->print(str);
1680 str->append(STRING_WITH_LEN(" in "));
1681 str->append(tab->table->getShare()->getTableName(), tab->table->getShare()->getTableNameSize());
1682 KeyInfo *key_info= tab->table->key_info+ tab->ref.key;
1683@@ -2843,12 +2840,12 @@
1684 if (cond)
1685 {
1686 str->append(STRING_WITH_LEN(" where "));
1687- cond->print(str, query_type);
1688+ cond->print(str);
1689 }
1690 if (having)
1691 {
1692 str->append(STRING_WITH_LEN(" having "));
1693- having->print(str, query_type);
1694+ having->print(str);
1695 }
1696 str->append(')');
1697 }
1698@@ -3244,13 +3241,13 @@
1699 Print the state of this engine into a string for debugging and views.
1700 */
1701
1702-void subselect_hash_sj_engine::print(String *str, enum_query_type query_type)
1703+void subselect_hash_sj_engine::print(String *str)
1704 {
1705 str->append(STRING_WITH_LEN(" <materialize> ("));
1706- materialize_engine->print(str, query_type);
1707+ materialize_engine->print(str);
1708 str->append(STRING_WITH_LEN(" ), "));
1709 if (tab)
1710- subselect_uniquesubquery_engine::print(str, query_type);
1711+ subselect_uniquesubquery_engine::print(str);
1712 else
1713 str->append(STRING_WITH_LEN(
1714 "<the access method for lookups is not yet created>"
1715
1716=== modified file 'drizzled/item/subselect.h'
1717--- drizzled/item/subselect.h 2011-02-17 00:14:13 +0000
1718+++ drizzled/item/subselect.h 2011-03-03 08:34:04 +0000
1719@@ -123,7 +123,7 @@
1720 inline bool get_const_item_cache() { return const_item_cache; }
1721 Item *get_tmp_table_item(Session *session);
1722 void update_used_tables();
1723- virtual void print(String *str, enum_query_type query_type);
1724+ virtual void print(String *str);
1725 virtual bool have_guarded_conds() { return false; }
1726 bool change_engine(subselect_engine *eng)
1727 {
1728@@ -222,7 +222,7 @@
1729 public:
1730 Item_maxmin_subselect(Session *session, Item_subselect *parent,
1731 Select_Lex *select_lex, bool max);
1732- virtual void print(String *str, enum_query_type query_type);
1733+ virtual void print(String *str);
1734 void cleanup();
1735 bool any_value() { return was_values; }
1736 void register_value() { was_values= true; }
1737@@ -253,7 +253,7 @@
1738 type::Decimal *val_decimal(type::Decimal *);
1739 bool val_bool();
1740 void fix_length_and_dec();
1741- virtual void print(String *str, enum_query_type query_type);
1742+ virtual void print(String *str);
1743
1744 friend class select_exists_subselect;
1745 friend class subselect_uniquesubquery_engine;
1746@@ -373,7 +373,7 @@
1747 void top_level_item() { abort_on_null=1; }
1748 inline bool is_top_level_item() { return abort_on_null; }
1749 bool test_limit(Select_Lex_Unit *unit);
1750- virtual void print(String *str, enum_query_type query_type);
1751+ virtual void print(String *str);
1752 bool fix_fields(Session *session, Item **ref);
1753 bool setup_engine();
1754 bool init_left_expr_cache();
1755@@ -401,7 +401,7 @@
1756 // only ALL subquery has upper not
1757 subs_type substype() { return all?ALL_SUBS:ANY_SUBS; }
1758 trans_res select_transformer(Join *join);
1759- virtual void print(String *str, enum_query_type query_type);
1760+ virtual void print(String *str);
1761 };
1762
1763
1764@@ -470,7 +470,7 @@
1765 virtual bool may_be_null() { return maybe_null; }
1766 virtual table_map upper_select_const_tables()= 0;
1767 static table_map calc_const_tables(TableList *);
1768- virtual void print(String *str, enum_query_type query_type)= 0;
1769+ virtual void print(String *str)= 0;
1770 virtual bool change_result(Item_subselect *si,
1771 select_result_interceptor *result)= 0;
1772 virtual bool no_tables()= 0;
1773@@ -504,7 +504,7 @@
1774 bool uncacheable(uint32_t bit_pos);
1775 void exclude();
1776 table_map upper_select_const_tables();
1777- virtual void print (String *str, enum_query_type query_type);
1778+ virtual void print (String *str);
1779 bool change_result(Item_subselect *si, select_result_interceptor *result);
1780 bool no_tables();
1781 bool may_be_null();
1782@@ -534,7 +534,7 @@
1783 bool uncacheable(uint32_t bit_pos);
1784 void exclude();
1785 table_map upper_select_const_tables();
1786- virtual void print (String *str, enum_query_type query_type);
1787+ virtual void print (String *str);
1788 bool change_result(Item_subselect *si, select_result_interceptor *result);
1789 bool no_tables();
1790 bool is_executed() const;
1791@@ -592,7 +592,7 @@
1792 bool uncacheable(uint32_t) { return true; }
1793 void exclude();
1794 table_map upper_select_const_tables() { return 0; }
1795- virtual void print (String *str, enum_query_type query_type);
1796+ virtual void print (String *str);
1797 bool change_result(Item_subselect *si, select_result_interceptor *result);
1798 bool no_tables();
1799 int scan_table();
1800@@ -647,7 +647,7 @@
1801 having(having_arg)
1802 {}
1803 int exec();
1804- virtual void print (String *str, enum_query_type query_type);
1805+ virtual void print (String *str);
1806 virtual enum_engine_type engine_type() { return INDEXSUBQUERY_ENGINE; }
1807 };
1808
1809@@ -704,7 +704,7 @@
1810 void cleanup();
1811 int prepare() { return 0; }
1812 int exec();
1813- virtual void print (String *str, enum_query_type query_type);
1814+ virtual void print (String *str);
1815 uint32_t cols()
1816 {
1817 return materialize_engine->cols();
1818
1819=== modified file 'drizzled/item/sum.cc'
1820--- drizzled/item/sum.cc 2011-02-24 19:13:33 +0000
1821+++ drizzled/item/sum.cc 2011-03-03 08:34:04 +0000
1822@@ -447,14 +447,14 @@
1823 }
1824
1825
1826-void Item_sum::print(String *str, enum_query_type query_type)
1827+void Item_sum::print(String *str)
1828 {
1829 str->append(func_name());
1830 for (uint32_t i=0 ; i < arg_count ; i++)
1831 {
1832 if (i)
1833 str->append(',');
1834- args[i]->print(str, query_type);
1835+ args[i]->print(str);
1836 }
1837 str->append(')');
1838 }
1839@@ -3366,7 +3366,7 @@
1840 }
1841
1842
1843-void Item_func_group_concat::print(String *str, enum_query_type query_type)
1844+void Item_func_group_concat::print(String *str)
1845 {
1846 str->append(STRING_WITH_LEN("group_concat("));
1847 if (distinct)
1848@@ -3375,7 +3375,7 @@
1849 {
1850 if (i)
1851 str->append(',');
1852- args[i]->print(str, query_type);
1853+ args[i]->print(str);
1854 }
1855 if (arg_count_order)
1856 {
1857@@ -3384,7 +3384,7 @@
1858 {
1859 if (i)
1860 str->append(',');
1861- (*order[i]->item)->print(str, query_type);
1862+ (*order[i]->item)->print(str);
1863 if (order[i]->asc)
1864 str->append(STRING_WITH_LEN(" ASC"));
1865 else
1866
1867=== modified file 'drizzled/item/sum.h'
1868--- drizzled/item/sum.h 2011-02-18 07:12:16 +0000
1869+++ drizzled/item/sum.h 2011-03-03 08:34:04 +0000
1870@@ -368,7 +368,7 @@
1871 virtual bool const_item() const { return forced_const; }
1872 virtual bool const_during_execution() const { return false; }
1873 void make_field(SendField *field);
1874- virtual void print(String *str, enum_query_type query_type);
1875+ virtual void print(String *str);
1876 void fix_num_length_and_dec();
1877
1878 /*
1879@@ -1043,7 +1043,7 @@
1880 String* val_str(String* str);
1881 Item *copy_or_same(Session* session);
1882 void no_rows_in_result() {}
1883- virtual void print(String *str, enum_query_type query_type);
1884+ virtual void print(String *str);
1885 virtual bool change_context_processor(unsigned char *cntx)
1886 { context= (Name_resolution_context *)cntx; return false; }
1887 };
1888
1889=== modified file 'drizzled/item/uint.cc'
1890--- drizzled/item/uint.cc 2011-02-17 00:14:13 +0000
1891+++ drizzled/item/uint.cc 2011-03-03 08:34:04 +0000
1892@@ -47,7 +47,7 @@
1893 return str;
1894 }
1895
1896-void Item_uint::print(String *str, enum_query_type)
1897+void Item_uint::print(String *str)
1898 {
1899 // latin1 is good enough for numbers
1900 str_value.set((uint64_t) value, default_charset());
1901
1902=== modified file 'drizzled/item/uint.h'
1903--- drizzled/item/uint.h 2010-12-18 04:43:40 +0000
1904+++ drizzled/item/uint.h 2011-03-03 08:34:04 +0000
1905@@ -36,7 +36,7 @@
1906 String *val_str(String*);
1907 Item *clone_item() { return new Item_uint(name, value, max_length); }
1908 int save_in_field(Field *field, bool no_conversions);
1909- virtual void print(String *str, enum_query_type query_type);
1910+ virtual void print(String *str);
1911 Item_num *neg ();
1912 uint32_t decimal_precision() const { return max_length; }
1913 };
1914
1915=== modified file 'drizzled/sql_lex.cc'
1916--- drizzled/sql_lex.cc 2011-02-27 02:20:23 +0000
1917+++ drizzled/sql_lex.cc 2011-03-03 08:34:04 +0000
1918@@ -1732,7 +1732,7 @@
1919 order_group_num)*5)) == 0;
1920 }
1921
1922-void Select_Lex_Unit::print(String *str, enum_query_type query_type)
1923+void Select_Lex_Unit::print(String *str)
1924 {
1925 bool union_all= !union_distinct;
1926 for (Select_Lex *sl= first_select(); sl; sl= sl->next_select())
1927@@ -1747,7 +1747,7 @@
1928 }
1929 if (sl->braces)
1930 str->append('(');
1931- sl->print(session, str, query_type);
1932+ sl->print(session, str);
1933 if (sl->braces)
1934 str->append(')');
1935 }
1936@@ -1758,16 +1758,14 @@
1937 str->append(STRING_WITH_LEN(" order by "));
1938 fake_select_lex->print_order(
1939 str,
1940- (Order *) fake_select_lex->order_list.first,
1941- query_type);
1942+ (Order *) fake_select_lex->order_list.first);
1943 }
1944- fake_select_lex->print_limit(session, str, query_type);
1945+ fake_select_lex->print_limit(session, str);
1946 }
1947 }
1948
1949 void Select_Lex::print_order(String *str,
1950- Order *order,
1951- enum_query_type query_type)
1952+ Order *order)
1953 {
1954 for (; order; order= order->next)
1955 {
1956@@ -1778,7 +1776,7 @@
1957 str->append(buffer, length);
1958 }
1959 else
1960- (*order->item)->print(str, query_type);
1961+ (*order->item)->print(str);
1962 if (!order->asc)
1963 str->append(STRING_WITH_LEN(" desc"));
1964 if (order->next)
1965@@ -1786,8 +1784,7 @@
1966 }
1967 }
1968
1969-void Select_Lex::print_limit(Session *, String *str,
1970- enum_query_type query_type)
1971+void Select_Lex::print_limit(Session *, String *str)
1972 {
1973 Select_Lex_Unit *unit= master_unit();
1974 Item_subselect *item= unit->item;
1975@@ -1818,10 +1815,10 @@
1976 str->append(STRING_WITH_LEN(" limit "));
1977 if (offset_limit)
1978 {
1979- offset_limit->print(str, query_type);
1980+ offset_limit->print(str);
1981 str->append(',');
1982 }
1983- select_limit->print(str, query_type);
1984+ select_limit->print(str);
1985 }
1986 }
1987
1988
1989=== modified file 'drizzled/sql_lex.h'
1990--- drizzled/sql_lex.h 2011-02-25 21:25:11 +0000
1991+++ drizzled/sql_lex.h 2011-03-03 08:34:04 +0000
1992@@ -378,7 +378,7 @@
1993 inline void unclean() { cleaned= 0; }
1994 void reinit_exec_mechanism();
1995
1996- void print(String *str, enum_query_type query_type);
1997+ void print(String *str);
1998
1999 bool add_fake_select_lex(Session *session);
2000 void init_prepare_fake_select_lex(Session *session);
2001@@ -646,11 +646,10 @@
2002 init_select();
2003 }
2004 bool setup_ref_array(Session *session, uint32_t order_group_num);
2005- void print(Session *session, String *str, enum_query_type query_type);
2006- static void print_order(String *str,
2007- Order *order,
2008- enum_query_type query_type);
2009- void print_limit(Session *session, String *str, enum_query_type query_type);
2010+ void print(Session *session, String *str);
2011+ static void print_order(String *str, Order *order);
2012+
2013+ void print_limit(Session *session, String *str);
2014 void fix_prepare_information(Session *session, Item **conds, Item **having_conds);
2015 /*
2016 Destroy the used execution plan (JOIN) of this subtree (this
2017
2018=== modified file 'drizzled/sql_parse.cc'
2019--- drizzled/sql_parse.cc 2011-02-25 21:25:11 +0000
2020+++ drizzled/sql_parse.cc 2011-03-03 08:34:04 +0000
2021@@ -583,7 +583,7 @@
2022 char buff[1024];
2023 String str(buff,(uint32_t) sizeof(buff), system_charset_info);
2024 str.length(0);
2025- session->getLex()->unit.print(&str, QT_ORDINARY);
2026+ session->getLex()->unit.print(&str);
2027 str.append('\0');
2028 push_warning(session, DRIZZLE_ERROR::WARN_LEVEL_NOTE,
2029 ER_YES, str.ptr());
2030
2031=== modified file 'drizzled/sql_select.cc'
2032--- drizzled/sql_select.cc 2011-03-01 18:51:28 +0000
2033+++ drizzled/sql_select.cc 2011-03-03 08:34:04 +0000
2034@@ -6252,7 +6252,7 @@
2035 static void print_table_array(Session *session, String *str, TableList **table,
2036 TableList **end)
2037 {
2038- (*table)->print(session, str, QT_ORDINARY);
2039+ (*table)->print(session, str);
2040
2041 for (TableList **tbl= table + 1; tbl < end; tbl++)
2042 {
2043@@ -6266,11 +6266,11 @@
2044 str->append(STRING_WITH_LEN(" straight_join "));
2045 else
2046 str->append(STRING_WITH_LEN(" join "));
2047- curr->print(session, str, QT_ORDINARY);
2048+ curr->print(session, str);
2049 if (curr->on_expr)
2050 {
2051 str->append(STRING_WITH_LEN(" on("));
2052- curr->on_expr->print(str, QT_ORDINARY);
2053+ curr->on_expr->print(str);
2054 str->append(')');
2055 }
2056 }
2057@@ -6281,10 +6281,9 @@
2058 @param session thread Cursor
2059 @param str string where table should be printed
2060 @param tables list of tables in join
2061- @query_type type of the query is being generated
2062 */
2063 void print_join(Session *session, String *str,
2064- List<TableList> *tables, enum_query_type)
2065+ List<TableList> *tables)
2066 {
2067 /* List is reversed => we should reverse it before using */
2068 List<TableList>::iterator ti(tables->begin());
2069@@ -6299,7 +6298,7 @@
2070 print_table_array(session, str, table, table + tables->size());
2071 }
2072
2073-void Select_Lex::print(Session *session, String *str, enum_query_type query_type)
2074+void Select_Lex::print(Session *session, String *str)
2075 {
2076 /* QQ: session may not be set for sub queries, but this should be fixed */
2077 if(not session)
2078@@ -6332,7 +6331,7 @@
2079 first= 0;
2080 else
2081 str->append(',');
2082- item->print_item_w_name(str, query_type);
2083+ item->print_item_w_name(str);
2084 }
2085
2086 /*
2087@@ -6343,7 +6342,7 @@
2088 {
2089 str->append(STRING_WITH_LEN(" from "));
2090 /* go through join tree */
2091- print_join(session, str, &top_join_list, query_type);
2092+ print_join(session, str, &top_join_list);
2093 }
2094 else if (where)
2095 {
2096@@ -6362,7 +6361,7 @@
2097 {
2098 str->append(STRING_WITH_LEN(" where "));
2099 if (cur_where)
2100- cur_where->print(str, query_type);
2101+ cur_where->print(str);
2102 else
2103 str->append(cond_value != Item::COND_FALSE ? "1" : "0");
2104 }
2105@@ -6371,7 +6370,7 @@
2106 if (group_list.size())
2107 {
2108 str->append(STRING_WITH_LEN(" group by "));
2109- print_order(str, (Order *) group_list.first, query_type);
2110+ print_order(str, (Order *) group_list.first);
2111 switch (olap)
2112 {
2113 case CUBE_TYPE:
2114@@ -6394,7 +6393,7 @@
2115 {
2116 str->append(STRING_WITH_LEN(" having "));
2117 if (cur_having)
2118- cur_having->print(str, query_type);
2119+ cur_having->print(str);
2120 else
2121 str->append(having_value != Item::COND_FALSE ? "1" : "0");
2122 }
2123@@ -6402,11 +6401,11 @@
2124 if (order_list.size())
2125 {
2126 str->append(STRING_WITH_LEN(" order by "));
2127- print_order(str, (Order *) order_list.first, query_type);
2128+ print_order(str, (Order *) order_list.first);
2129 }
2130
2131 // limit
2132- print_limit(session, str, query_type);
2133+ print_limit(session, str);
2134
2135 // PROCEDURE unsupported here
2136 }
2137
2138=== modified file 'drizzled/sql_select.h'
2139--- drizzled/sql_select.h 2011-02-17 00:14:13 +0000
2140+++ drizzled/sql_select.h 2011-03-03 08:34:04 +0000
2141@@ -281,8 +281,7 @@
2142 COND *remove_eq_conds(Session *session, COND *cond, Item::cond_result *cond_value);
2143 int test_if_item_cache_changed(List<Cached_item> &list);
2144
2145-void print_join(Session *session, String *str,
2146- List<TableList> *tables, enum_query_type);
2147+void print_join(Session *session, String *str, List<TableList> *tables);
2148
2149 } /* namespace drizzled */
2150
2151
2152=== modified file 'drizzled/table_list.cc'
2153--- drizzled/table_list.cc 2011-02-24 14:51:56 +0000
2154+++ drizzled/table_list.cc 2011-03-03 08:34:04 +0000
2155@@ -261,12 +261,12 @@
2156 return 0;
2157 }
2158
2159-void TableList::print(Session *session, String *str, enum_query_type query_type)
2160+void TableList::print(Session *session, String *str)
2161 {
2162 if (nested_join)
2163 {
2164 str->append('(');
2165- print_join(session, str, &nested_join->join_list, query_type);
2166+ print_join(session, str, &nested_join->join_list);
2167 str->append(')');
2168 }
2169 else
2170@@ -276,7 +276,7 @@
2171 {
2172 // A derived table
2173 str->append('(');
2174- derived->print(str, query_type);
2175+ derived->print(str);
2176 str->append(')');
2177 cmp_name= ""; // Force printing of alias
2178 }
2179
2180=== modified file 'drizzled/table_list.h'
2181--- drizzled/table_list.h 2011-02-09 21:31:01 +0000
2182+++ drizzled/table_list.h 2011-03-03 08:34:04 +0000
2183@@ -253,7 +253,7 @@
2184 *
2185 * @param str string where table should be printed
2186 */
2187- void print(Session *session, String *str, enum_query_type query_type);
2188+ void print(Session *session, String *str);
2189 /**
2190 * Sets insert_values buffer
2191 *
2192
2193=== modified file 'plugin/benchmark/benchmarkudf.cc'
2194--- plugin/benchmark/benchmarkudf.cc 2011-02-24 19:13:33 +0000
2195+++ plugin/benchmark/benchmarkudf.cc 2011-03-03 08:34:04 +0000
2196@@ -31,7 +31,7 @@
2197 public:
2198 BenchmarkFunction() :Item_int_func() {}
2199 int64_t val_int();
2200- virtual void print(String *str, enum_query_type query_type);
2201+ virtual void print(String *str);
2202
2203 const char *func_name() const
2204 {
2205@@ -107,12 +107,12 @@
2206 return 0;
2207 }
2208
2209-void BenchmarkFunction::print(String *str, enum_query_type query_type)
2210+void BenchmarkFunction::print(String *str)
2211 {
2212 str->append(STRING_WITH_LEN("benchmark("));
2213- args[0]->print(str, query_type);
2214+ args[0]->print(str);
2215 str->append(',');
2216- args[1]->print(str, query_type);
2217+ args[1]->print(str);
2218 str->append(')');
2219 }
2220
2221
2222=== modified file 'plugin/string_functions/format.cc'
2223--- plugin/string_functions/format.cc 2011-02-17 00:14:13 +0000
2224+++ plugin/string_functions/format.cc 2011-03-03 08:34:04 +0000
2225@@ -130,12 +130,12 @@
2226 }
2227
2228
2229-void Item_func_format::print(String *str, enum_query_type query_type)
2230+void Item_func_format::print(String *str)
2231 {
2232 str->append(STRING_WITH_LEN("format("));
2233- args[0]->print(str, query_type);
2234+ args[0]->print(str);
2235 str->append(',');
2236- args[1]->print(str, query_type);
2237+ args[1]->print(str);
2238 str->append(')');
2239 }
2240
2241
2242=== modified file 'plugin/string_functions/format.h'
2243--- plugin/string_functions/format.h 2010-12-18 04:43:40 +0000
2244+++ plugin/string_functions/format.h 2011-03-03 08:34:04 +0000
2245@@ -34,7 +34,7 @@
2246 String *val_str(String *);
2247 void fix_length_and_dec();
2248 const char *func_name() const { return "format"; }
2249- virtual void print(String *str, enum_query_type query_type);
2250+ virtual void print(String *str);
2251 bool check_argument_count(int n) { return n == 2; }
2252 };
2253
2254
2255=== modified file 'plugin/utility_functions/assert.cc'
2256--- plugin/utility_functions/assert.cc 2011-02-17 00:14:13 +0000
2257+++ plugin/utility_functions/assert.cc 2011-03-03 08:34:04 +0000
2258@@ -34,7 +34,7 @@
2259 if (not args[0]->val_bool())
2260 {
2261 drizzled::String res;
2262- args[0]->print(&res, QT_ORDINARY);
2263+ args[0]->print(&res);
2264
2265 assert(res.c_ptr());
2266

Subscribers

People subscribed via source and target branches