diff options
Diffstat (limited to 'sql/item.h')
-rw-r--r-- | sql/item.h | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/sql/item.h b/sql/item.h index 6900fa11b90..23c5c844f21 100644 --- a/sql/item.h +++ b/sql/item.h @@ -41,16 +41,22 @@ class DTCollation { public: CHARSET_INFO *collation; enum Derivation derivation; + uint nagg; // Total number of aggregated collations. + uint strong; // Number of the strongest collation. DTCollation() { collation= &my_charset_bin; derivation= DERIVATION_NONE; + nagg= 0; + strong= 0; } DTCollation(CHARSET_INFO *collation_arg, Derivation derivation_arg) { collation= collation_arg; derivation= derivation_arg; + nagg= 0; + strong= 0; } void set(DTCollation &dt) { @@ -66,9 +72,9 @@ public: { collation= collation_arg; } void set(Derivation derivation_arg) { derivation= derivation_arg; } - bool aggregate(DTCollation &dt); - bool set(DTCollation &dt1, DTCollation &dt2) - { set(dt1); return aggregate(dt2); } + bool aggregate(DTCollation &dt, bool superset_conversion= FALSE); + bool set(DTCollation &dt1, DTCollation &dt2, bool superset_conversion= FALSE) + { set(dt1); return aggregate(dt2, superset_conversion); } const char *derivation_name() const { switch(derivation) @@ -239,6 +245,7 @@ public: virtual void top_level_item() {} virtual void set_result_field(Field *field) {} virtual bool is_result_field() { return 0; } + virtual bool is_bool_func() { return 0; } virtual void save_in_result_field(bool no_conversions) {} virtual void no_rows_in_result() {} virtual Item *copy_or_same(THD *thd) { return this; } @@ -268,8 +275,7 @@ public: virtual void bring_value() {} Field *tmp_table_field_from_field_type(TABLE *table); - - /* Used in sql_select.cc:eliminate_not_funcs() */ + virtual Item *neg_transformer(THD *thd) { return NULL; } void delete_self() { |