Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fix feature count in postgres provider
git-svn-id: http://svn.osgeo.org/qgis/trunk@10426 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef committed Mar 27, 2009
1 parent a2d3b38 commit 9addfdb
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/providers/postgres/qgspostgresprovider.cpp
Expand Up @@ -622,7 +622,7 @@ bool QgsPostgresProvider::nextFeature( QgsFeature& feature )
feature.setAttributeMap( mFeatureQueue.front().attributeMap() );

mFeatureQueue.pop();

feature.setValid( true );
return true;
}
Expand Down Expand Up @@ -1873,6 +1873,8 @@ bool QgsPostgresProvider::addFeatures( QgsFeatureList & flist )

connectionRW->PQexecNR( "DEALLOCATE addfeatures" );
connectionRW->PQexecNR( "COMMIT" );

featuresCounted += flist.size();
}
catch ( PGException &e )
{
Expand Down Expand Up @@ -1913,6 +1915,8 @@ bool QgsPostgresProvider::deleteFeatures( const QgsFeatureIds & id )
}

connectionRW->PQexecNR( "COMMIT" );

featuresCounted -= id.size();
}
catch ( PGException &e )
{
Expand Down

0 comments on commit 9addfdb

Please sign in to comment.