~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/item.cc

  • Committer: Jay Pipes
  • Date: 2009-02-12 18:16:06 UTC
  • mto: This revision was merged to the branch mainline in revision 883.
  • Revision ID: jpipes@serialcoder-20090212181606-vi7rd85rufufqxvc
Fixes Arg_comparator::can_compare_as_dates to never, ever allow bad
input data in comparisons.  No more implicit conversions from bad
datetimes are allowed.  We throw an error on bad input always.

In addition, fixes the Field_date class's store() methods for integer
types and corrects test cases that were allowing bad input.

Show diffs side-by-side

added added

removed removed

Lines of Context:
297
297
                      collation.collation);
298
298
}
299
299
 
300
 
 
301
300
Item::Item():
302
301
  is_expensive_cache(-1), name(0), orig_name(0), max_length(0), name_length(0),
303
302
  unsigned_flag(false), fixed(0), is_autogenerated_name(true),
325
324
  {
326
325
    enum_parsing_place place=
327
326
      session->lex->current_select->parsing_place;
328
 
    if (place == SELECT_LIST ||
329
 
        place == IN_HAVING)
 
327
    if (place == SELECT_LIST || place == IN_HAVING)
330
328
      session->lex->current_select->select_n_having_items++;
331
329
  }
332
330
}