diff options
author | Bill King <bking@trolltech.com> | 2009-07-02 05:00:03 (GMT) |
---|---|---|
committer | Bill King <bking@trolltech.com> | 2009-07-02 05:02:13 (GMT) |
commit | 18055b3c3fe50337ee1af819839694674bdfb3ff (patch) | |
tree | 5e89430a62a5ba74182943ace4fb4d186e07596c /src/sql/drivers/odbc | |
parent | a24b8166631a9b1d80f8205cd0e450824166a25d (diff) | |
download | Qt-18055b3c3fe50337ee1af819839694674bdfb3ff.zip Qt-18055b3c3fe50337ee1af819839694674bdfb3ff.tar.gz Qt-18055b3c3fe50337ee1af819839694674bdfb3ff.tar.bz2 |
Tinyint is unsigned, force it to such.
Tinyint only supports 0-255, so mark it as unsigned despite sign flag,
which have the time is inverted/wrong.
Diffstat (limited to 'src/sql/drivers/odbc')
-rw-r--r-- | src/sql/drivers/odbc/qsql_odbc.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/sql/drivers/odbc/qsql_odbc.cpp b/src/sql/drivers/odbc/qsql_odbc.cpp index e18a9eb..4f358ec 100644 --- a/src/sql/drivers/odbc/qsql_odbc.cpp +++ b/src/sql/drivers/odbc/qsql_odbc.cpp @@ -252,9 +252,11 @@ static QVariant::Type qDecodeODBCType(SQLSMALLINT sqltype, const T* p, bool isSi case SQL_SMALLINT: case SQL_INTEGER: case SQL_BIT: - case SQL_TINYINT: type = isSigned ? QVariant::Int : QVariant::UInt; break; + case SQL_TINYINT: + type = QVariant::UInt; + break; case SQL_BIGINT: type = isSigned ? QVariant::LongLong : QVariant::ULongLong; break; |