spatialite provider: load 64bit integers (fixes #12785)

This commit is contained in:
Juergen E. Fischer 2015-06-09 23:12:27 +02:00
parent 014f0703fe
commit b736317005

View File

@ -369,8 +369,16 @@ QVariant QgsSpatiaLiteFeatureIterator::getFeatureAttribute( sqlite3_stmt* stmt,
{
if ( sqlite3_column_type( stmt, ic ) == SQLITE_INTEGER )
{
// INTEGER value
return sqlite3_column_int( stmt, ic );
if ( type == QVariant::Int )
{
// INTEGER value
return sqlite3_column_int( stmt, ic );
}
else
{
// INTEGER value
return ( qint64 ) sqlite3_column_int64( stmt, ic );
}
}
if ( sqlite3_column_type( stmt, ic ) == SQLITE_FLOAT )