summaryrefslogtreecommitdiff
path: root/connectivity
diff options
context:
space:
mode:
authorWastack <btomi96@gmail.com>2016-11-29 10:10:30 +0100
committerLionel Elie Mamane <lionel@mamane.lu>2016-12-11 10:40:57 +0000
commitea61a62323fe398d682da5bbf5b0d9e17d442212 (patch)
treed0c820f3af6235db6e28708bde5429e7c8e43bf2 /connectivity
parentae18926c2fae5e36256561b60c74990150e5fbdc (diff)
tdf#104227 query boolean like infos correctly
Change-Id: Ic862bb1ce3efa61d6a01fc56fb9e84cf98bb7cd0 Reviewed-on: https://gerrit.libreoffice.org/31355 Reviewed-by: Lionel Elie Mamane <lionel@mamane.lu> Tested-by: Lionel Elie Mamane <lionel@mamane.lu>
Diffstat (limited to 'connectivity')
-rw-r--r--connectivity/source/drivers/firebird/DatabaseMetaData.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/connectivity/source/drivers/firebird/DatabaseMetaData.cxx b/connectivity/source/drivers/firebird/DatabaseMetaData.cxx
index 4c2e3934e735..959b134a0505 100644
--- a/connectivity/source/drivers/firebird/DatabaseMetaData.cxx
+++ b/connectivity/source/drivers/firebird/DatabaseMetaData.cxx
@@ -1124,7 +1124,8 @@ uno::Reference< XResultSet > SAL_CALL ODatabaseMetaData::getColumnPrivileges(
aCurrentRow[5] = new ORowSetValueDecorator(xRow->getString(2)); // 5. GRANTOR
aCurrentRow[6] = new ORowSetValueDecorator(xRow->getString(3)); // 6. GRANTEE
aCurrentRow[7] = new ORowSetValueDecorator(xRow->getString(4)); // 7. Privilege
- aCurrentRow[7] = new ORowSetValueDecorator(xRow->getBoolean(5)); // 8. Grantable
+ aCurrentRow[7] = new ORowSetValueDecorator( ( xRow->getShort(5) == 1 ) ?
+ OUString("YES") : OUString("NO")); // 8. Grantable
aResults.push_back(aCurrentRow);
}
@@ -1721,7 +1722,7 @@ uno::Reference< XResultSet > SAL_CALL ODatabaseMetaData::getIndexInfo(
}
// 4. NON_UNIQUE -- i.e. specifically negate here.
- aCurrentRow[4] = new ORowSetValueDecorator(!xRow->getBoolean(5));
+ aCurrentRow[4] = new ORowSetValueDecorator(xRow->getShort(5) == 0);
// 6. INDEX NAME
aCurrentRow[6] = new ORowSetValueDecorator(sanitizeIdentifier(xRow->getString(4)));