~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/field/datetime.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:
120
120
int Field_datetime::store(int64_t from, bool)
121
121
{
122
122
  /* 
123
 
   * Try to create a DateTime from the supplied string.  Throw an error
 
123
   * Try to create a DateTime from the supplied integer.  Throw an error
124
124
   * if unable to create a valid DateTime.  
125
125
   */
126
126
  drizzled::DateTime temporal;