Skip to content
Permalink
Browse files
Fix loading of spatialite table after creation
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@13258 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
gsherman committed Apr 6, 2010
1 parent e15562b commit cd8b6c7d1fab6a7f043cc44ee1e338612f5a7841
Showing with 1 addition and 2 deletions.
  1. +1 −2 src/app/qgisapp.cpp
@@ -2810,7 +2810,6 @@ void QgisApp::addSpatiaLiteLayer()
layername.truncate( idx );

// create the layer
//qWarning("creating layer");
QgsVectorLayer *layer = new QgsVectorLayer( "dbname='" + connectionInfo + "' table=" + *it + ") sql=", layername, "spatialite" );
if ( layer->isValid() )
{
@@ -3209,7 +3208,7 @@ void QgisApp::newSpatialiteLayer()
sqlite3_free( errmsg );
}

QgsVectorLayer *layer = new QgsVectorLayer( QString( "dbname=%1 table=%2(%3) sql=" )
QgsVectorLayer *layer = new QgsVectorLayer( QString( "dbname='%1' table='%2'(%3) sql=" )
.arg( databaseName )
.arg( newLayerName )
.arg( newGeometryColumn ), newLayerName, "spatialite" );

0 comments on commit cd8b6c7

Please sign in to comment.