Skip to content
Permalink
Browse files

Apply suggestions from code review

Co-authored-by: Matthias Kuhn <matthias@opengis.ch>
  • Loading branch information
2 people authored and nyalldawson committed Jun 17, 2020
1 parent 4b36262 commit e55751bc95d05baec403e876f7e9eaefe90e98f4
Showing with 3 additions and 4 deletions.
  1. +1 −2 src/core/providers/ogr/qgsogrprovider.cpp
  2. +2 −2 src/core/qgssqliteutils.cpp
@@ -1485,7 +1485,7 @@ QVariant QgsOgrProvider::defaultValue( int fieldId ) const

if ( ! ok )
{
QgsMessageLog::logMessage( tr( "Error retrieving next sequence value for %1" ).arg( QString( mOgrOrigLayer->name() ) ), tr( "OGR" ) );
QgsMessageLog::logMessage( tr( "Error retrieving next sequence value for %1" ).arg( QString::fromUtf8( mOgrOrigLayer->name() ) ), tr( "OGR" ) );
}
}
else // no sequence!
@@ -6923,4 +6923,3 @@ void QgsOgrProviderMetadata::saveConnection( const QgsAbstractProviderConnection
}

///@endcond

@@ -233,8 +233,8 @@ long long QgsSqliteUtils::nextSequenceValue( sqlite3 *connection, const QString
else // increment
{
if ( dsPtr.exec( QStringLiteral( "UPDATE sqlite_sequence SET seq = %1 WHERE name = %2" )
.arg( QString::number( ++result ) )
.arg( quotedTableName ), errorMessage ) != SQLITE_OK )
.arg( QString::number( ++result ),
quotedTableName ), errorMessage ) != SQLITE_OK )
{
errorMessage = QObject::tr( "Error retrieving default value for %1" ).arg( tableName );
result = -1;

0 comments on commit e55751b

Please sign in to comment.
You can’t perform that action at this time.