Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Really delete deleted features in ogr provider (using REPACK)
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@6821 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent committed Mar 19, 2007
1 parent c15c054 commit 02e4fd1
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/providers/ogr/qgsogrprovider.cpp
Expand Up @@ -1005,7 +1005,13 @@ bool QgsOgrProvider::deleteFeatures(const QgsFeatureIds & id)
returnvalue=false;
}
}

ogrLayer->SyncToDisk();
QString filename=dataSourceUri().section('/',-1,-1);//find out the filename from the uri
QString layername=filename.section('.',0,0);
QString sql="REPACK " + layername;
ogrDataSource->ExecuteSQL(sql.toLocal8Bit().data(), NULL, NULL);

return returnvalue;
}

Expand Down

0 comments on commit 02e4fd1

Please sign in to comment.