We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
qgis
Learn more about funding links in repositories.
Report abuse
There was an error while loading. Please reload this page.
2 parents 84db88b + f5d81ae commit b5dc778Copy full SHA for b5dc778
src/providers/mssql/qgsmssqlprovider.cpp
@@ -370,12 +370,21 @@ void QgsMssqlProvider::loadFields()
370
{
371
pkCandidates << query.value( 3 ).toString();
372
}
373
- mAttributeFields.append(
374
- QgsField(
375
- query.value( 3 ).toString(), sqlType,
376
- sqlTypeName,
377
- query.value( 7 ).toInt(),
378
- query.value( 6 ).toInt() ) );
+ if ( sqlType == QVariant::String )
+ {
+ mAttributeFields.append(
+ QgsField(
+ query.value( 3 ).toString(), sqlType,
+ sqlTypeName,
379
+ query.value( 7 ).toInt() ) );
380
+ }
381
+ else
382
383
384
385
386
+ sqlTypeName ) );
387
388
389
if ( !query.value( 12 ).isNull() )
390
0 commit comments