~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/time_functions.cc

  • Committer: Monty Taylor
  • Date: 2010-10-02 05:07:25 UTC
  • mto: (1817.1.3 build)
  • mto: This revision was merged to the branch mainline in revision 1818.
  • Revision ID: mordred@inaugust.com-20101002050725-h1b30b0nr3leeoh1
Embed a modified version of parse_config_file. There are several more bugs
that we'll want to fix in it, and then submit upstream. Eventually we should
be able to remove this- but for now the version on lucid is completely
broken.

Show diffs side-by-side

added added

removed removed

Lines of Context:
131
131
                          uint32_t flags)
132
132
{
133
133
  int was_cut;
 
134
  enum enum_drizzle_timestamp_type ts_type;
134
135
  Session *session= current_session;
135
 
  enum enum_drizzle_timestamp_type ts_type;
136
136
 
137
137
  ts_type= str_to_datetime(str, length, l_time,
138
138
                           (flags | (session->variables.sql_mode &
140
140
                                      MODE_NO_ZERO_DATE))),
141
141
                           &was_cut);
142
142
  if (was_cut || ts_type <= DRIZZLE_TIMESTAMP_ERROR)
143
 
    make_truncated_value_warning(current_session, DRIZZLE_ERROR::WARN_LEVEL_WARN,
 
143
    make_truncated_value_warning(session, DRIZZLE_ERROR::WARN_LEVEL_WARN,
144
144
                                 str, length, ts_type,  NULL);
145
145
  return ts_type;
146
146
}
216
216
      break;
217
217
  }
218
218
  if (field_name)
 
219
  {
219
220
    cs->cset->snprintf(cs, warn_buff, sizeof(warn_buff),
220
221
                       ER(ER_TRUNCATED_WRONG_VALUE_FOR_FIELD),
221
222
                       type_str, str.c_ptr(), field_name,
222
223
                       (uint32_t) session->row_count);
 
224
  }
223
225
  else
224
226
  {
225
227
    if (time_type > DRIZZLE_TIMESTAMP_ERROR)