~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to client/drizzledump_drizzle.cc

  • Committer: lbieber
  • Date: 2010-10-01 16:29:19 UTC
  • mfrom: (1804.1.1 build)
  • Revision ID: lbieber@orisndriz08-20101001162919-ecqsatl39e2sgt4l
Merge Andrew - Fix bug 651948 - Index lengths not retrieved using drizzledump

Show diffs side-by-side

added added

removed removed

Lines of Context:
208
208
  if (verbose)
209
209
    std::cerr << _("-- Retrieving indexes for ") << tableName << "..." << std::endl;
210
210
 
211
 
  query= "SELECT INDEX_NAME, COLUMN_NAME, IS_USED_IN_PRIMARY, IS_UNIQUE FROM DATA_DICTIONARY.INDEX_PARTS WHERE TABLE_NAME='";
 
211
  query= "SELECT INDEX_NAME, COLUMN_NAME, IS_USED_IN_PRIMARY, IS_UNIQUE, COMPARE_LENGTH FROM DATA_DICTIONARY.INDEX_PARTS WHERE TABLE_NAME='";
212
212
  query.append(tableName);
213
213
  query.append("'");
214
214
 
228
228
      index->isPrimary= (strcmp(row[0], "PRIMARY") == 0);
229
229
      index->isUnique= (strcmp(row[3], "YES") == 0);
230
230
      index->isHash= 0;
 
231
      index->length= (row[4]) ? boost::lexical_cast<uint32_t>(row[4]) : 0;
231
232
      lastKey= row[0];
232
233
      firstIndex= false;
233
234
    }