~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/item_sum.h

MergedĀ fromĀ PatG.

Show diffs side-by-side

added added

removed removed

Lines of Context:
650
650
  enum_field_types field_type() const
651
651
  {
652
652
    return hybrid_type == DECIMAL_RESULT ?
653
 
      FIELD_TYPE_NEWDECIMAL : FIELD_TYPE_DOUBLE;
 
653
      DRIZZLE_TYPE_NEWDECIMAL : DRIZZLE_TYPE_DOUBLE;
654
654
  }
655
655
  void fix_length_and_dec() {}
656
656
  enum Item_result result_type () const { return hybrid_type; }
718
718
  enum_field_types field_type() const
719
719
  {
720
720
    return hybrid_type == DECIMAL_RESULT ?
721
 
      FIELD_TYPE_NEWDECIMAL : FIELD_TYPE_DOUBLE;
 
721
      DRIZZLE_TYPE_NEWDECIMAL : DRIZZLE_TYPE_DOUBLE;
722
722
  }
723
723
  void fix_length_and_dec() {}
724
724
  enum Item_result result_type () const { return hybrid_type; }
796
796
  double val_real();
797
797
  my_decimal *val_decimal(my_decimal *);
798
798
  enum Item_result result_type () const { return REAL_RESULT; }
799
 
  enum_field_types field_type() const { return FIELD_TYPE_DOUBLE;}
 
799
  enum_field_types field_type() const { return DRIZZLE_TYPE_DOUBLE;}
800
800
};
801
801
 
802
802
/*
818
818
  const char *func_name() const { return "std("; }
819
819
  Item *copy_or_same(THD* thd);
820
820
  enum Item_result result_type () const { return REAL_RESULT; }
821
 
  enum_field_types field_type() const { return FIELD_TYPE_DOUBLE;}
 
821
  enum_field_types field_type() const { return DRIZZLE_TYPE_DOUBLE;}
822
822
};
823
823
 
824
824
// This class is a string or number function depending on num_func
838
838
  public:
839
839
  Item_sum_hybrid(Item *item_par,int sign)
840
840
    :Item_sum(item_par), sum(0.0), sum_int(0),
841
 
    hybrid_type(INT_RESULT), hybrid_field_type(FIELD_TYPE_LONGLONG),
 
841
    hybrid_type(INT_RESULT), hybrid_field_type(DRIZZLE_TYPE_LONGLONG),
842
842
    cmp_sign(sign), was_values(true)
843
843
  { collation.set(&my_charset_bin); }
844
844
  Item_sum_hybrid(THD *thd, Item_sum_hybrid *item);
1153
1153
  enum_field_types field_type() const
1154
1154
  {
1155
1155
    if (max_length/collation.collation->mbmaxlen > CONVERT_IF_BIGGER_TO_BLOB )
1156
 
      return FIELD_TYPE_BLOB;
 
1156
      return DRIZZLE_TYPE_BLOB;
1157
1157
    else
1158
 
      return FIELD_TYPE_VARCHAR;
 
1158
      return DRIZZLE_TYPE_VARCHAR;
1159
1159
  }
1160
1160
  void clear();
1161
1161
  bool add();