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>
This commit is contained in:
Wastack 2016-11-29 10:10:30 +01:00 committed by Lionel Elie Mamane
parent ae18926c2f
commit ea61a62323

View File

@ -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)));