~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/type/decimal.cc

  • Committer: Brian Aker
  • Date: 2011-01-13 00:08:59 UTC
  • mto: (2082.4.1 timestamp)
  • mto: This revision was merged to the branch mainline in revision 2098.
  • Revision ID: brian@tangent.org-20110113000859-8dw4ybnp8id56u50
Fix issue with return value from unix_timestamp(). Also clean up error
messages, and remove limit on value for timestamp.

Show diffs side-by-side

added added

removed removed

Lines of Context:
320
320
  date = (ltime->year*100L + ltime->month)*100L + ltime->day;
321
321
  if (ltime->time_type > DRIZZLE_TIMESTAMP_DATE)
322
322
    date= ((date*100L + ltime->hour)*100L+ ltime->minute)*100L + ltime->second;
 
323
 
323
324
  if (int2_class_decimal(E_DEC_FATAL_ERROR, date, false, dec))
324
325
    return dec;
 
326
 
325
327
  if (ltime->second_part)
326
328
  {
327
329
    dec->buf[(dec->intg-1) / 9 + 1]= ltime->second_part * 1000;