summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--connectivity/source/drivers/adabas/BColumns.cxx6
-rw-r--r--connectivity/source/drivers/adabas/BGroups.cxx6
-rw-r--r--connectivity/source/drivers/adabas/BIndexes.cxx11
-rw-r--r--connectivity/source/drivers/adabas/BKeys.cxx6
-rw-r--r--connectivity/source/drivers/adabas/BTables.cxx6
-rw-r--r--connectivity/source/drivers/adabas/BUsers.cxx6
-rw-r--r--connectivity/source/drivers/adabas/BViews.cxx23
-rw-r--r--connectivity/source/drivers/ado/AColumns.cxx6
-rw-r--r--connectivity/source/drivers/ado/AGroups.cxx6
-rw-r--r--connectivity/source/drivers/ado/AIndexes.cxx6
-rw-r--r--connectivity/source/drivers/ado/AKeys.cxx6
-rw-r--r--connectivity/source/drivers/ado/ATables.cxx6
-rw-r--r--connectivity/source/drivers/ado/AUsers.cxx8
-rw-r--r--connectivity/source/drivers/ado/AViews.cxx6
-rw-r--r--connectivity/source/drivers/calc/CTables.cxx6
-rw-r--r--connectivity/source/drivers/file/FCatalog.cxx27
-rw-r--r--connectivity/source/drivers/file/FConnection.cxx5
-rw-r--r--connectivity/source/drivers/file/FDatabaseMetaData.cxx16
-rw-r--r--connectivity/source/drivers/flat/EDatabaseMetaData.cxx30
-rw-r--r--connectivity/source/drivers/flat/ETables.cxx6
-rw-r--r--connectivity/source/drivers/odbc/OResultSet.cxx12
-rw-r--r--connectivity/source/inc/file/FCatalog.hxx5
-rw-r--r--connectivity/source/inc/file/FConnection.hxx6
23 files changed, 134 insertions, 87 deletions
diff --git a/connectivity/source/drivers/adabas/BColumns.cxx b/connectivity/source/drivers/adabas/BColumns.cxx
index dfc7a3c98b93..f42e87ac4db1 100644
--- a/connectivity/source/drivers/adabas/BColumns.cxx
+++ b/connectivity/source/drivers/adabas/BColumns.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: BColumns.cxx,v $
*
- * $Revision: 1.5 $
+ * $Revision: 1.6 $
*
- * last change: $Author: oj $ $Date: 2000-11-08 14:08:31 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:19 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -225,7 +225,7 @@ void SAL_CALL OColumns::dropByIndex( sal_Int32 index ) throw(SQLException, Index
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
if(!m_pTable->isNew())
{
diff --git a/connectivity/source/drivers/adabas/BGroups.cxx b/connectivity/source/drivers/adabas/BGroups.cxx
index db34c46f1844..9d5853cce9a4 100644
--- a/connectivity/source/drivers/adabas/BGroups.cxx
+++ b/connectivity/source/drivers/adabas/BGroups.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: BGroups.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: oj $ $Date: 2000-10-24 15:54:39 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:19 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -154,7 +154,7 @@ void SAL_CALL OGroups::dropByIndex( sal_Int32 index ) throw(SQLException, IndexO
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
dropByName(m_aElements[index]->first);
}
diff --git a/connectivity/source/drivers/adabas/BIndexes.cxx b/connectivity/source/drivers/adabas/BIndexes.cxx
index 66772496ecd4..14dbc0dc764a 100644
--- a/connectivity/source/drivers/adabas/BIndexes.cxx
+++ b/connectivity/source/drivers/adabas/BIndexes.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: BIndexes.cxx,v $
*
- * $Revision: 1.9 $
+ * $Revision: 1.10 $
*
- * last change: $Author: fs $ $Date: 2001-03-16 09:34:22 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:19 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -83,6 +83,10 @@
#ifndef _CONNECTIVITY_PROPERTYIDS_HXX_
#include "propertyids.hxx"
#endif
+#ifndef _COMPHELPER_TYPES_HXX_
+#include <comphelper/types.hxx>
+#endif
+
using namespace connectivity::adabas;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
@@ -233,6 +237,7 @@ void SAL_CALL OIndexes::dropByName( const ::rtl::OUString& elementName ) throw(S
Reference< XStatement > xStmt = m_pTable->getConnection()->createStatement( );
xStmt->execute(aSql);
+ ::comphelper::disposeComponent(xStmt);
}
OCollection_TYPE::dropByName(elementName);
}
@@ -241,7 +246,7 @@ void SAL_CALL OIndexes::dropByIndex( sal_Int32 index ) throw(SQLException, Index
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
dropByName(m_aElements[index]->first);
}
diff --git a/connectivity/source/drivers/adabas/BKeys.cxx b/connectivity/source/drivers/adabas/BKeys.cxx
index 72bbab86e27d..c3ff6c947a59 100644
--- a/connectivity/source/drivers/adabas/BKeys.cxx
+++ b/connectivity/source/drivers/adabas/BKeys.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: BKeys.cxx,v $
*
- * $Revision: 1.7 $
+ * $Revision: 1.8 $
*
- * last change: $Author: oj $ $Date: 2001-02-28 10:14:27 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:19 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -314,7 +314,7 @@ void SAL_CALL OKeys::dropByIndex( sal_Int32 index ) throw(SQLException, IndexOut
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
dropByName(m_aElements[index]->first);
}
diff --git a/connectivity/source/drivers/adabas/BTables.cxx b/connectivity/source/drivers/adabas/BTables.cxx
index d727d8e1a463..1c39aff3c1ec 100644
--- a/connectivity/source/drivers/adabas/BTables.cxx
+++ b/connectivity/source/drivers/adabas/BTables.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: BTables.cxx,v $
*
- * $Revision: 1.9 $
+ * $Revision: 1.10 $
*
- * last change: $Author: oj $ $Date: 2001-03-29 07:02:32 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:19 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -268,7 +268,7 @@ void SAL_CALL OTables::dropByIndex( sal_Int32 index ) throw(SQLException, IndexO
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
dropByName((*m_aElements[index]).first);
}
diff --git a/connectivity/source/drivers/adabas/BUsers.cxx b/connectivity/source/drivers/adabas/BUsers.cxx
index 13feda8b04e8..ca0c29de09ea 100644
--- a/connectivity/source/drivers/adabas/BUsers.cxx
+++ b/connectivity/source/drivers/adabas/BUsers.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: BUsers.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: oj $ $Date: 2000-10-24 15:54:39 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:19 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -168,7 +168,7 @@ void SAL_CALL OUsers::dropByIndex( sal_Int32 index ) throw(SQLException, IndexOu
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
dropByName(m_aElements[index]->first);
}
diff --git a/connectivity/source/drivers/adabas/BViews.cxx b/connectivity/source/drivers/adabas/BViews.cxx
index 66d7e7587863..43d8c5fad955 100644
--- a/connectivity/source/drivers/adabas/BViews.cxx
+++ b/connectivity/source/drivers/adabas/BViews.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: BViews.cxx,v $
*
- * $Revision: 1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: oj $ $Date: 2001-03-29 07:03:17 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:19 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -122,9 +122,14 @@ Reference< XNamed > OViews::createObject(const ::rtl::OUString& _rName)
aSchema = _rName.copy(0,nLen);
aName = _rName.copy(nLen+1);
- ::rtl::OUString sStmt = ::rtl::OUString::createFromAscii("SELECT DISTINCT DOMAIN.VIEWDEFS.DEFINITION FROM DOMAIN.VIEWDEFS WHERE DOMAIN.VIEWDEFS.OWNER = '");
- sStmt += aSchema;
- sStmt += ::rtl::OUString::createFromAscii("' AND DOMAIN.VIEWDEFS.VIEWNAME = '");
+ ::rtl::OUString sStmt = ::rtl::OUString::createFromAscii("SELECT DISTINCT * FROM DOMAIN.SHOW_VIEW WHERE ");
+ if(aSchema.getLength())
+ {
+ sStmt += ::rtl::OUString::createFromAscii("OWNER = '");
+ sStmt += aSchema;
+ sStmt += ::rtl::OUString::createFromAscii("' AND ");
+ }
+ sStmt += ::rtl::OUString::createFromAscii("VIEWNAME = '");
sStmt += aName;
sStmt += ::rtl::OUString::createFromAscii("'");
Reference< XStatement > xStmt = static_cast<OAdabasCatalog&>(m_rParent).getConnection()->createStatement( );
@@ -136,7 +141,11 @@ Reference< XNamed > OViews::createObject(const ::rtl::OUString& _rName)
Reference< XRow > xRow(xResult,UNO_QUERY);
if(xResult->next()) // there can be only one table with this name
{
- connectivity::sdbcx::OView* pRet = new connectivity::sdbcx::OView(sal_True,aName,CheckOption::NONE,xRow->getString(1),aSchema);
+ connectivity::sdbcx::OView* pRet = new connectivity::sdbcx::OView(sal_True,
+ aName,
+ CheckOption::NONE,
+ xRow->getString(3),
+ aSchema);
xRet = pRet;
}
}
@@ -221,7 +230,7 @@ void SAL_CALL OViews::dropByIndex( sal_Int32 index ) throw(SQLException, IndexOu
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
dropByName((*m_aElements[index]).first);
}
diff --git a/connectivity/source/drivers/ado/AColumns.cxx b/connectivity/source/drivers/ado/AColumns.cxx
index d8b69dd34764..aeb25026cb36 100644
--- a/connectivity/source/drivers/ado/AColumns.cxx
+++ b/connectivity/source/drivers/ado/AColumns.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: AColumns.cxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: oj $ $Date: 2000-11-03 14:09:51 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:20 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -139,7 +139,7 @@ void SAL_CALL OColumns::dropByIndex( sal_Int32 index ) throw(SQLException, Index
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
m_pCollection->Delete(OLEVariant(index));
OCollection_TYPE::dropByIndex(index);
diff --git a/connectivity/source/drivers/ado/AGroups.cxx b/connectivity/source/drivers/ado/AGroups.cxx
index d3e75885d029..354580f7e2eb 100644
--- a/connectivity/source/drivers/ado/AGroups.cxx
+++ b/connectivity/source/drivers/ado/AGroups.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: AGroups.cxx,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 16:14:20 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:20 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -135,7 +135,7 @@ void SAL_CALL OGroups::dropByIndex( sal_Int32 index ) throw(SQLException, IndexO
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
m_pCollection->Delete(OLEVariant(index));
diff --git a/connectivity/source/drivers/ado/AIndexes.cxx b/connectivity/source/drivers/ado/AIndexes.cxx
index eb93fd71fa87..ac5593641657 100644
--- a/connectivity/source/drivers/ado/AIndexes.cxx
+++ b/connectivity/source/drivers/ado/AIndexes.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: AIndexes.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: oj $ $Date: 2000-11-03 14:09:51 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:20 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -138,7 +138,7 @@ void SAL_CALL OIndexes::dropByIndex( sal_Int32 index ) throw(SQLException, Index
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
m_pCollection->Delete(OLEVariant(index));
diff --git a/connectivity/source/drivers/ado/AKeys.cxx b/connectivity/source/drivers/ado/AKeys.cxx
index 78eaef03572e..f3b246e2a236 100644
--- a/connectivity/source/drivers/ado/AKeys.cxx
+++ b/connectivity/source/drivers/ado/AKeys.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: AKeys.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: oj $ $Date: 2000-11-03 14:09:51 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:20 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -145,7 +145,7 @@ void SAL_CALL OKeys::dropByIndex( sal_Int32 index ) throw(SQLException, IndexOut
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
m_pCollection->Delete(OLEVariant(index));
diff --git a/connectivity/source/drivers/ado/ATables.cxx b/connectivity/source/drivers/ado/ATables.cxx
index c5418298ff6e..8825781c41c1 100644
--- a/connectivity/source/drivers/ado/ATables.cxx
+++ b/connectivity/source/drivers/ado/ATables.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: ATables.cxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: oj $ $Date: 2000-11-03 14:09:51 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:20 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -147,7 +147,7 @@ void SAL_CALL OTables::dropByIndex( sal_Int32 index ) throw(SQLException, IndexO
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
m_pCollection->Delete(OLEVariant(index));
diff --git a/connectivity/source/drivers/ado/AUsers.cxx b/connectivity/source/drivers/ado/AUsers.cxx
index 29a2c9bf3f56..23ca857dfb63 100644
--- a/connectivity/source/drivers/ado/AUsers.cxx
+++ b/connectivity/source/drivers/ado/AUsers.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: AUsers.cxx,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 16:14:21 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:20 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -135,10 +135,12 @@ void SAL_CALL OUsers::dropByIndex( sal_Int32 index ) throw(SQLException, IndexOu
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
m_pCollection->Delete(OLEVariant(index));
OCollection_TYPE::dropByIndex(index);
}
+// -----------------------------------------------------------------------------
+
diff --git a/connectivity/source/drivers/ado/AViews.cxx b/connectivity/source/drivers/ado/AViews.cxx
index 3767c6f59be0..b97c68c0aff7 100644
--- a/connectivity/source/drivers/ado/AViews.cxx
+++ b/connectivity/source/drivers/ado/AViews.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: AViews.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: oj $ $Date: 2000-10-24 16:11:26 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:20 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -148,7 +148,7 @@ void SAL_CALL OViews::dropByIndex( sal_Int32 index ) throw(SQLException, IndexOu
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
m_pCollection->Delete(OLEVariant(index));
diff --git a/connectivity/source/drivers/calc/CTables.cxx b/connectivity/source/drivers/calc/CTables.cxx
index 03c92d648e07..27f5de7311e2 100644
--- a/connectivity/source/drivers/calc/CTables.cxx
+++ b/connectivity/source/drivers/calc/CTables.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: CTables.cxx,v $
*
- * $Revision: 1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: nn $ $Date: 2001-01-26 19:05:48 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:20 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -184,7 +184,7 @@ void SAL_CALL OCalcTables::dropByIndex( sal_Int32 index ) throw(SQLException, In
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
dropByName((*m_aElements[index]).first);
}
diff --git a/connectivity/source/drivers/file/FCatalog.cxx b/connectivity/source/drivers/file/FCatalog.cxx
index a72d711d689c..c8e3ee7149ec 100644
--- a/connectivity/source/drivers/file/FCatalog.cxx
+++ b/connectivity/source/drivers/file/FCatalog.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: FCatalog.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: oj $ $Date: 2000-10-17 09:05:49 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:21 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -132,4 +132,27 @@ Any SAL_CALL OFileCatalog::queryInterface( const Type & rType ) throw(RuntimeExc
typedef sdbcx::OCatalog OFileCatalog_BASE;
return OFileCatalog_BASE::queryInterface(rType);
}
+// -----------------------------------------------------------------------------
+Sequence< Type > SAL_CALL OFileCatalog::getTypes( ) throw(RuntimeException)
+{
+ typedef sdbcx::OCatalog OFileCatalog_BASE;
+
+ Sequence< Type > aTypes = OFileCatalog_BASE::getTypes();
+ Sequence< Type > aRet(aTypes.getLength()-3);
+ const Type* pBegin = aTypes.getConstArray();
+ const Type* pEnd = pBegin + aTypes.getLength();
+ sal_Int32 i=0;
+ for(;pBegin != pEnd;++pBegin,++i)
+ {
+ if(!(*pBegin == ::getCppuType((const Reference<XGroupsSupplier>*)0) ||
+ *pBegin == ::getCppuType((const Reference<XUsersSupplier>*)0) ||
+ *pBegin == ::getCppuType((const Reference<XViewsSupplier>*)0)))
+ {
+ aRet.getArray()[i] = *pBegin;
+ }
+ }
+ return aRet;
+}
+// -----------------------------------------------------------------------------
+
diff --git a/connectivity/source/drivers/file/FConnection.cxx b/connectivity/source/drivers/file/FConnection.cxx
index f64813ab72b9..527a82d1b839 100644
--- a/connectivity/source/drivers/file/FConnection.cxx
+++ b/connectivity/source/drivers/file/FConnection.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: FConnection.cxx,v $
*
- * $Revision: 1.19 $
+ * $Revision: 1.20 $
*
- * last change: $Author: oj $ $Date: 2001-03-01 15:50:48 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:08:05 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -174,6 +174,7 @@ void OConnection::construct(const ::rtl::OUString& url,const Sequence< PropertyV
// String aFileName = aURL.PathToFileName();
aFileName = aURL.GetMainURL();
+ m_aURL = aFileName;
if(!aFileName.Len())
aFileName = aDSN;
diff --git a/connectivity/source/drivers/file/FDatabaseMetaData.cxx b/connectivity/source/drivers/file/FDatabaseMetaData.cxx
index 41f4dc3236e5..cfa161c7ebf3 100644
--- a/connectivity/source/drivers/file/FDatabaseMetaData.cxx
+++ b/connectivity/source/drivers/file/FDatabaseMetaData.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: FDatabaseMetaData.cxx,v $
*
- * $Revision: 1.15 $
+ * $Revision: 1.16 $
*
- * last change: $Author: oj $ $Date: 2001-03-28 11:31:44 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:21 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -102,6 +102,7 @@
using namespace com::sun::star::ucb;
using namespace connectivity::file;
+using namespace connectivity;
using namespace com::sun::star::uno;
using namespace com::sun::star::lang;
using namespace com::sun::star::beans;
@@ -122,13 +123,10 @@ ODatabaseMetaData::~ODatabaseMetaData()
Reference< XResultSet > SAL_CALL ODatabaseMetaData::getTypeInfo( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
-
-
-// OResultSet* pResult = new OResultSet(hStmt);
-// Reference< XResultSet > xRef = pResult;
-// pResult->openTypeInfo();
-// return xRef;
- return Reference< XResultSet >();
+ ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ Reference< XResultSet > xRef = pResult;
+ pResult->setTypeInfoMap();
+ return xRef;
}
// -------------------------------------------------------------------------
Reference< XResultSet > SAL_CALL ODatabaseMetaData::getCatalogs( ) throw(SQLException, RuntimeException)
diff --git a/connectivity/source/drivers/flat/EDatabaseMetaData.cxx b/connectivity/source/drivers/flat/EDatabaseMetaData.cxx
index 28ab98c7ebef..073c9483d294 100644
--- a/connectivity/source/drivers/flat/EDatabaseMetaData.cxx
+++ b/connectivity/source/drivers/flat/EDatabaseMetaData.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: EDatabaseMetaData.cxx,v $
*
- * $Revision: 1.9 $
+ * $Revision: 1.10 $
*
- * last change: $Author: oj $ $Date: 2001-03-28 11:31:45 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:21 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -101,9 +101,9 @@
#include <comphelper/extract.hxx>
#endif
-
+using namespace connectivity;
using namespace connectivity::flat;
-using namespace connectivity::file;
+// using namespace connectivity::file;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::sdbcx;
@@ -112,7 +112,7 @@ using namespace ::com::sun::star::container;
-OFlatDatabaseMetaData::OFlatDatabaseMetaData(OConnection* _pCon) :ODatabaseMetaData(_pCon)
+OFlatDatabaseMetaData::OFlatDatabaseMetaData(::connectivity::file::OConnection* _pCon) :ODatabaseMetaData(_pCon)
{
}
// -------------------------------------------------------------------------
@@ -124,7 +124,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getTypeInfo( ) throw(SQ
{
::osl::MutexGuard aGuard( m_aMutex );
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setTypeInfoMap();
ORows aRows;
@@ -226,7 +226,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getColumnPrivileges(
{
::osl::MutexGuard aGuard( m_aMutex );
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setColumnPrivilegesMap();
return xRef;
@@ -323,7 +323,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getColumns(
}
}
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setColumnsMap();
pResult->setRows(aRows);
@@ -336,7 +336,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getVersionColumns(
{
::osl::MutexGuard aGuard( m_aMutex );
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setVersionColumnsMap();
return xRef;
@@ -347,7 +347,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getExportedKeys(
{
::osl::MutexGuard aGuard( m_aMutex );
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setExportedKeysMap();
return xRef;
@@ -358,7 +358,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getImportedKeys(
{
::osl::MutexGuard aGuard( m_aMutex );
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setImportedKeysMap();
return xRef;
@@ -369,7 +369,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getPrimaryKeys(
{
::osl::MutexGuard aGuard( m_aMutex );
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setPrimaryKeysMap();
return xRef;
@@ -381,7 +381,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getIndexInfo(
{
::osl::MutexGuard aGuard( m_aMutex );
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setIndexInfoMap();
return xRef;
@@ -393,7 +393,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getBestRowIdentifier(
{
::osl::MutexGuard aGuard( m_aMutex );
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setBestRowIdentifierMap();
return xRef;
@@ -406,7 +406,7 @@ Reference< XResultSet > SAL_CALL OFlatDatabaseMetaData::getCrossReference(
{
::osl::MutexGuard aGuard( m_aMutex );
- ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet();
+ ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet();
Reference< XResultSet > xRef = pResult;
pResult->setCrossReferenceMap();
return xRef;
diff --git a/connectivity/source/drivers/flat/ETables.cxx b/connectivity/source/drivers/flat/ETables.cxx
index 30fa23456aaf..bbc404eb6159 100644
--- a/connectivity/source/drivers/flat/ETables.cxx
+++ b/connectivity/source/drivers/flat/ETables.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: ETables.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: oj $ $Date: 2000-11-03 14:16:38 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:21 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -168,7 +168,7 @@ void SAL_CALL OFlatTables::dropByIndex( sal_Int32 index ) throw(SQLException, In
{
::osl::MutexGuard aGuard(m_rMutex);
if (index < 0 || index >= getCount())
- throw IndexOutOfBoundsException();
+ throw IndexOutOfBoundsException(::rtl::OUString::valueOf(index),*this);
dropByName((*m_aElements[index]).first);
}
diff --git a/connectivity/source/drivers/odbc/OResultSet.cxx b/connectivity/source/drivers/odbc/OResultSet.cxx
index 49261285f207..41da45a12785 100644
--- a/connectivity/source/drivers/odbc/OResultSet.cxx
+++ b/connectivity/source/drivers/odbc/OResultSet.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: OResultSet.cxx,v $
*
- * $Revision: 1.15 $
+ * $Revision: 1.16 $
*
- * last change: $Author: jl $ $Date: 2001-03-20 16:54:34 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:22 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -443,7 +443,13 @@ Sequence< sal_Int8 > SAL_CALL OResultSet::getBytes( sal_Int32 columnIndex ) thro
if(columnIndex > m_nLastColumnPos)
fillRow(columnIndex);
Sequence< sal_Int8 > nRet;
- m_aRow[columnIndex] >>= nRet;
+ if(!(m_aRow[columnIndex] >>= nRet) && m_aRow[columnIndex].hasValue())
+ { // something went wrong so we have another type here
+ OSL_ENSURE(TypeClass_STRING == m_aRow[columnIndex].getValueTypeClass(),"ONLY string types supported!");
+ ::rtl::OUString sRet;
+ m_aRow[columnIndex] >>= sRet;
+ return Sequence<sal_Int8>(reinterpret_cast<const sal_Int8*>(sRet.getStr()),sizeof(sal_Unicode)*sRet.getLength());
+ }
return nRet;
}
diff --git a/connectivity/source/inc/file/FCatalog.hxx b/connectivity/source/inc/file/FCatalog.hxx
index 259ea76cf139..51875ca30547 100644
--- a/connectivity/source/inc/file/FCatalog.hxx
+++ b/connectivity/source/inc/file/FCatalog.hxx
@@ -2,9 +2,9 @@
*
* $RCSfile: FCatalog.hxx,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 16:14:26 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:22 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -90,6 +90,7 @@ namespace connectivity
virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException);
// ::cppu::OComponentHelper
+ virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes( ) throw(::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL disposing(void);
};
}
diff --git a/connectivity/source/inc/file/FConnection.hxx b/connectivity/source/inc/file/FConnection.hxx
index 07001d48d400..0a86f542e3cc 100644
--- a/connectivity/source/inc/file/FConnection.hxx
+++ b/connectivity/source/inc/file/FConnection.hxx
@@ -2,9 +2,9 @@
*
* $RCSfile: FConnection.hxx,v $
*
- * $Revision: 1.6 $
+ * $Revision: 1.7 $
*
- * last change: $Author: oj $ $Date: 2001-02-05 12:26:41 $
+ * last change: $Author: oj $ $Date: 2001-03-30 14:07:22 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -211,8 +211,10 @@ namespace connectivity
// create a catalog or return the catalog already created
virtual ::com::sun::star::uno::Reference< ::com::sun::star::sdbcx::XTablesSupplier > createCatalog();
String getExtension() const { return m_aFilenameExtension;}
+ String getURL() const { return m_aURL; }
OFileDriver* getDriver() const { return m_pDriver; }
+
};
}
}