Skip to content

Commit 098c578

Browse files
committedMay 14, 2020
Even less chatty
1 parent 2e10281 commit 098c578

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed
 

‎src/providers/mssql/qgsmssqlprovider.cpp

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -703,7 +703,7 @@ void QgsMssqlProvider::UpdateStatistics( bool estimate ) const
703703
!query.value( 2 ).isNull() ||
704704
!query.value( 3 ).isNull() ) )
705705
{
706-
QgsDebugMsg( QStringLiteral( "Found extents in spatial index" ) );
706+
QgsDebugMsgLevel( QStringLiteral( "Found extents in spatial index" ), 2 );
707707
mExtent.setXMinimum( query.value( 0 ).toDouble() );
708708
mExtent.setYMinimum( query.value( 1 ).toDouble() );
709709
mExtent.setXMaximum( query.value( 2 ).toDouble() );
@@ -2121,7 +2121,7 @@ bool QgsMssqlProviderMetadata::saveStyle( const QString &uri, const QString &qml
21212121
}
21222122
if ( query.isActive() && query.next() && query.value( 0 ).toInt() == 0 )
21232123
{
2124-
QgsDebugMsg( QStringLiteral( "Need to create styles table" ) );
2124+
QgsDebugMsgLevel( QStringLiteral( "Need to create styles table" ), 2 );
21252125
bool execOk = query.exec( QString( "CREATE TABLE [dbo].[layer_styles]("
21262126
"[id] int IDENTITY(1,1) PRIMARY KEY,"
21272127
"[f_table_catalog] [varchar](1024) NULL,"
@@ -2153,7 +2153,7 @@ bool QgsMssqlProviderMetadata::saveStyle( const QString &uri, const QString &qml
21532153
uiFileColumn = QStringLiteral( ",ui" );
21542154
uiFileValue = QStringLiteral( ",XMLPARSE(DOCUMENT %1)" ).arg( uiFileContent );
21552155
}
2156-
QgsDebugMsg( QStringLiteral( "Ready to insert new style" ) );
2156+
QgsDebugMsgLevel( QStringLiteral( "Ready to insert new style" ), 2 );
21572157
// Note: in the construction of the INSERT and UPDATE strings the qmlStyle and sldStyle values
21582158
// can contain user entered strings, which may themselves include %## values that would be
21592159
// replaced by the QString.arg function. To ensure that the final SQL string is not corrupt these
@@ -2208,7 +2208,7 @@ bool QgsMssqlProviderMetadata::saveStyle( const QString &uri, const QString &qml
22082208
return false;
22092209
}
22102210

2211-
QgsDebugMsg( QStringLiteral( "Updating styles" ) );
2211+
QgsDebugMsgLevel( QStringLiteral( "Updating styles" ), 2 );
22122212
sql = QString( "UPDATE layer_styles "
22132213
" SET useAsDefault=%1"
22142214
",styleQML=%2"
@@ -2246,8 +2246,8 @@ bool QgsMssqlProviderMetadata::saveStyle( const QString &uri, const QString &qml
22462246
sql = QStringLiteral( "%1; %2;" ).arg( removeDefaultSql, sql );
22472247
}
22482248

2249-
QgsDebugMsg( QStringLiteral( "Inserting styles" ) );
2250-
QgsDebugMsg( sql );
2249+
QgsDebugMsgLevel( QStringLiteral( "Inserting styles" ), 2 );
2250+
QgsDebugMsgLevel( sql, 2 );
22512251
bool execOk = query.exec( sql );
22522252

22532253
if ( !execOk )
@@ -2352,7 +2352,7 @@ int QgsMssqlProviderMetadata::listStyles( const QString &uri, QStringList &ids,
23522352
int numberOfRelatedStyles = 0;
23532353
while ( query.isActive() && query.next() )
23542354
{
2355-
QgsDebugMsg( query.value( 1 ).toString() );
2355+
QgsDebugMsgLevel( query.value( 1 ).toString(), 2 );
23562356
ids.append( query.value( 0 ).toString() );
23572357
names.append( query.value( 1 ).toString() );
23582358
descriptions.append( query.value( 2 ).toString() );
@@ -2366,14 +2366,14 @@ int QgsMssqlProviderMetadata::listStyles( const QString &uri, QStringList &ids,
23662366
.arg( QgsMssqlProvider::quotedValue( dsUri.schema() ) )
23672367
.arg( QgsMssqlProvider::quotedValue( dsUri.table() ) )
23682368
.arg( QgsMssqlProvider::quotedValue( dsUri.geometryColumn() ) );
2369-
QgsDebugMsg( selectOthersQuery );
2369+
QgsDebugMsgLevel( selectOthersQuery, 2 );
23702370
queryOk = query.exec( selectOthersQuery );
23712371
if ( !queryOk )
23722372
{
23732373
QgsDebugMsg( query.lastError().text() );
23742374
return -1;
23752375
}
2376-
QgsDebugMsg( query.isActive() && query.size() );
2376+
QgsDebugMsgLevel( query.isActive() && query.size(), 2 );
23772377
while ( query.next() )
23782378
{
23792379
ids.append( query.value( 0 ).toString() );

0 commit comments

Comments
 (0)
Please sign in to comment.