Commit a4621b67 authored by Philippe Pebay's avatar Philippe Pebay
Browse files

ENH: by default (and this is the case e.g. for SQLite), index names

     are not supported when creating either a PRIMARY or a UNIQUE index
     within a CREATE TABLE statement. Make this the default implementation
     at the parent class level, in order to avoid potential problems with
     yet unknown database backends.
parent ae621421
......@@ -39,7 +39,7 @@ PURPOSE. See the above copyright notice for more information.
#include <vtksys/SystemTools.hxx>
#include <vtksys/ios/sstream>
vtkCxxRevisionMacro(vtkSQLDatabase, "1.34");
vtkCxxRevisionMacro(vtkSQLDatabase, "1.35");
// ----------------------------------------------------------------------
......@@ -218,7 +218,11 @@ vtkStdString vtkSQLDatabase::GetIndexSpecification( vtkSQLDatabaseSchema* schema
return vtkStdString();
// No index_name for PRIMARY KEYs nor UNIQUEs
if ( skipped )
queryStr += schema->GetIndexNameFromHandle( tblHandle, idxHandle );
// CREATE INDEX <index name> ON <table name> syntax
if ( skipped )
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment