diff options
author | Lionel Elie Mamane <lionel@mamane.lu> | 2012-11-01 10:36:44 +0100 |
---|---|---|
committer | Lionel Elie Mamane <lionel@mamane.lu> | 2012-11-02 10:51:03 +0100 |
commit | 20380f26b47faffe0cf541f46b8706439a5d4219 (patch) | |
tree | 39232214be8d2413cc70ff29aefb549d6c0df185 /connectivity | |
parent | 6747cc436886b8bb07852fe71a0b404eb9300f48 (diff) |
Retrieve CatalogName only once, too
Diffstat (limited to 'connectivity')
-rw-r--r-- | connectivity/source/commontools/TIndexColumns.cxx | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/connectivity/source/commontools/TIndexColumns.cxx b/connectivity/source/commontools/TIndexColumns.cxx index 1cee8098d837..7edd3ea706df 100644 --- a/connectivity/source/commontools/TIndexColumns.cxx +++ b/connectivity/source/commontools/TIndexColumns.cxx @@ -48,12 +48,12 @@ sdbcx::ObjectType OIndexColumns::createObject(const ::rtl::OUString& _rName) { ::dbtools::OPropertyMap& rPropMap = OMetaConnection::getPropMap(); ::rtl::OUString aSchema,aTable; + ::com::sun::star::uno::Any Catalog(m_pIndex->getTable()->getPropertyValue(rPropMap.getNameByIndex(PROPERTY_ID_CATALOGNAME))); m_pIndex->getTable()->getPropertyValue(rPropMap.getNameByIndex(PROPERTY_ID_SCHEMANAME)) >>= aSchema; m_pIndex->getTable()->getPropertyValue(rPropMap.getNameByIndex(PROPERTY_ID_NAME)) >>= aTable; Reference< XResultSet > xResult = m_pIndex->getTable()->getConnection()->getMetaData()->getIndexInfo( - m_pIndex->getTable()->getPropertyValue(rPropMap.getNameByIndex(PROPERTY_ID_CATALOGNAME)), - aSchema,aTable,sal_False,sal_False); + Catalog, aSchema, aTable, sal_False, sal_False); sal_Bool bAsc = sal_True; if ( xResult.is() ) @@ -68,8 +68,7 @@ sdbcx::ObjectType OIndexColumns::createObject(const ::rtl::OUString& _rName) } xResult = m_pIndex->getTable()->getConnection()->getMetaData()->getColumns( - m_pIndex->getTable()->getPropertyValue(rPropMap.getNameByIndex(PROPERTY_ID_CATALOGNAME)), - aSchema,aTable,_rName); + Catalog, aSchema, aTable, _rName); sdbcx::ObjectType xRet; if ( xResult.is() ) |