Skip to content
Permalink
Browse files
postgres provider: fix indexing of default values (fixes #12996; foll…
…oup 61f39d6)
  • Loading branch information
jef-n committed Jun 30, 2015
1 parent 79d37c1 commit b1dac74f2baa17eed89f6652e0d3c1653d8483e9
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/providers/postgres/qgspostgresprovider.cpp
@@ -1785,12 +1785,12 @@ bool QgsPostgresProvider::addFeatures( QgsFeatureList &flist )
if ( value.isNull() )
{
const QgsField &fld = field( attrIdx );
v = paramValue( defaultValues[ attrIdx ], defaultValues[ attrIdx ] );
v = paramValue( defaultValues[ i ], defaultValues[ i ] );
features->setAttribute( attrIdx, convertValue( fld.type(), v ) );
}
else
{
v = paramValue( value.toString(), defaultValues[ attrIdx ] );
v = paramValue( value.toString(), defaultValues[ i ] );

if ( v != value.toString() )
{

0 comments on commit b1dac74

Please sign in to comment.