merge the formfield patch from ooo-build
[ooovba.git] / connectivity / source / drivers / file / FDatabaseMetaData.cxx
blobd4a8b0d19654c0d2bf3ac62b47ae5210c40861f7
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: FDatabaseMetaData.cxx,v $
10 * $Revision: 1.36 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 // MARKER(update_precomp.py): autogen include statement, do not remove
32 #include "precompiled_connectivity.hxx"
33 #include "file/FDatabaseMetaData.hxx"
34 #include "FDatabaseMetaDataResultSet.hxx"
35 #include <com/sun/star/sdbc/DataType.hpp>
36 #include <com/sun/star/sdbc/ResultSetType.hpp>
37 #include <com/sun/star/sdbc/ResultSetConcurrency.hpp>
38 #include <com/sun/star/ucb/SearchRecursion.hpp>
39 #include <com/sun/star/ucb/SearchCommandArgument.hpp>
40 #include <com/sun/star/ucb/XSortedDynamicResultSetFactory.hpp>
41 #include <com/sun/star/ucb/XContentProvider.hpp>
42 #include <com/sun/star/lang/XUnoTunnel.hpp>
43 #include <tools/urlobj.hxx>
44 #include "file/FDriver.hxx"
45 #include "file/FTable.hxx"
46 #include <comphelper/extract.hxx>
47 #include <ucbhelper/content.hxx>
48 #include <ucbhelper/contentbroker.hxx>
49 #include <tools/debug.hxx>
50 #include <rtl/logfile.hxx>
53 using namespace com::sun::star::ucb;
54 using namespace connectivity::file;
55 using namespace connectivity;
56 using namespace com::sun::star::uno;
57 using namespace com::sun::star::lang;
58 using namespace com::sun::star::beans;
59 using namespace com::sun::star::sdbc;
60 using namespace com::sun::star::sdbcx;
61 using namespace com::sun::star::lang;
62 using namespace com::sun::star::container;
64 DBG_NAME( file_ODatabaseMetaData )
65 ODatabaseMetaData::ODatabaseMetaData(OConnection* _pCon) : ::connectivity::ODatabaseMetaDataBase(_pCon,_pCon->getConnectionInfo())
66 ,m_pConnection(_pCon)
68 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::ODatabaseMetaData" );
69 DBG_CTOR( file_ODatabaseMetaData, NULL );
71 // -------------------------------------------------------------------------
72 ODatabaseMetaData::~ODatabaseMetaData()
74 DBG_DTOR( file_ODatabaseMetaData, NULL );
76 // -------------------------------------------------------------------------
77 Reference< XResultSet > ODatabaseMetaData::impl_getTypeInfo_throw( )
79 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_getTypeInfo_throw" );
80 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eTypeInfo );
82 // -------------------------------------------------------------------------
83 ::rtl::OUString ODatabaseMetaData::impl_getCatalogSeparator_throw( )
85 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_getCatalogSeparator_throw" );
86 return ::rtl::OUString();
88 // -------------------------------------------------------------------------
89 Reference< XResultSet > SAL_CALL ODatabaseMetaData::getColumns(
90 const Any& /*catalog*/, const ::rtl::OUString& /*schemaPattern*/, const ::rtl::OUString& /*tableNamePattern*/,
91 const ::rtl::OUString& /*columnNamePattern*/ ) throw(SQLException, RuntimeException)
93 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getColumns" );
94 OSL_ENSURE(0,"Should be overloaded!");
95 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eColumns );
98 // -------------------------------------------------------------------------
99 namespace
101 sal_Int16 isCaseSensitiveParentFolder( const String& _rFolderOrDoc, const String& _rDocName )
103 sal_Int16 nIsCS = 1;
106 // first get the real content for the URL
107 INetURLObject aContentURL( _rFolderOrDoc );
108 ::ucbhelper::Content aContent1;
110 ::ucbhelper::Content aFolderOrDoc( _rFolderOrDoc, Reference< XCommandEnvironment >() );
111 if ( aFolderOrDoc.isDocument() )
112 aContent1 = aFolderOrDoc;
113 else
115 aContentURL = INetURLObject( _rFolderOrDoc, INetURLObject::WAS_ENCODED );
116 aContentURL.Append( _rDocName );
117 aContent1 = ::ucbhelper::Content( aContentURL.GetMainURL( INetURLObject::NO_DECODE ), Reference< XCommandEnvironment >() );
121 // get two extensions which differ by case only
122 String sExtension1 = aContentURL.getExtension();
123 String sExtension2( sExtension1 );
124 sExtension2.ToLowerAscii();
125 if ( sExtension2 == sExtension1 )
126 // the extension was already in lower case
127 sExtension2.ToUpperAscii();
129 // the complete URL for the second extension
130 INetURLObject aURL2( aContentURL );
131 if ( sExtension2.Len() )
132 aURL2.SetExtension( sExtension2 );
133 if ( aURL2.GetMainURL(INetURLObject::NO_DECODE) == aContentURL.GetMainURL(INetURLObject::NO_DECODE) )
134 return -1;
136 // the second context
137 sal_Bool bCanAccess = sal_False;
138 ::ucbhelper::Content aContent2;
141 aContent2 = ::ucbhelper::Content( aURL2.GetMainURL( INetURLObject::NO_DECODE ), Reference< XCommandEnvironment >() );
142 bCanAccess = aContent2.isDocument();
144 catch( const Exception& )
148 if ( bCanAccess )
150 // here we have two contents whose URLs differ by case only.
151 // Now let's check if both really refer to the same object ....
152 Reference< XContent > xContent1 = aContent1.get();
153 Reference< XContent > xContent2 = aContent2.get();
154 OSL_ENSURE( xContent1.is() && xContent2.is(), "isCaseSensitiveParentFolder: invalid content interfaces!" );
155 if ( xContent1.is() && xContent2.is() )
157 Reference< XContentIdentifier > xID1 = xContent1->getIdentifier();
158 Reference< XContentIdentifier > xID2 = xContent2->getIdentifier();
159 OSL_ENSURE( xID1.is() && xID2.is(), "isCaseSensitiveParentFolder: invalid ID interfaces!" );
160 if ( xID1.is() && xID2.is() )
162 // get a generic content provider
163 ::ucbhelper::ContentBroker* pBroker = ::ucbhelper::ContentBroker::get();
164 Reference< XContentProvider > xProvider;
165 if ( pBroker )
166 xProvider = pBroker->getContentProviderInterface();
167 OSL_ENSURE( xProvider.is(), "isCaseSensitiveParentFolder: invalid content broker!" );
168 if ( xProvider.is() )
170 if ( 0 == xProvider->compareContentIds( xID1, xID2 ) )
171 // finally, we know that the folder is not case-sensitive ....
172 nIsCS = 0;
178 catch( const Exception& )
180 OSL_ENSURE( sal_False, "isCaseSensitiveParentFolder: caught an unexpected exception!" );
183 return nIsCS;
187 // -------------------------------------------------------------------------
188 Reference< XResultSet > SAL_CALL ODatabaseMetaData::getTables(
189 const Any& /*catalog*/, const ::rtl::OUString& /*schemaPattern*/,
190 const ::rtl::OUString& tableNamePattern, const Sequence< ::rtl::OUString >& types ) throw(SQLException, RuntimeException)
192 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getTables" );
193 ::osl::MutexGuard aGuard( m_aMutex );
196 ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eTables );
197 Reference< XResultSet > xRef = pResult;
199 // check if any type is given
200 // when no types are given then we have to return all tables e.g. TABLE
202 static const ::rtl::OUString aTable(::rtl::OUString::createFromAscii("TABLE"));
204 sal_Bool bTableFound = sal_True;
205 sal_Int32 nLength = types.getLength();
206 if(nLength)
208 bTableFound = sal_False;
210 const ::rtl::OUString* pBegin = types.getConstArray();
211 const ::rtl::OUString* pEnd = pBegin + nLength;
212 for(;pBegin != pEnd;++pBegin)
214 if(*pBegin == aTable)
216 bTableFound = sal_True;
217 break;
221 if(!bTableFound)
222 return xRef;
224 Reference<XDynamicResultSet> xContent = m_pConnection->getDir();
225 Reference < XSortedDynamicResultSetFactory > xSRSFac(
226 m_pConnection->getDriver()->getFactory()->createInstance( ::rtl::OUString::createFromAscii("com.sun.star.ucb.SortedDynamicResultSetFactory") ), UNO_QUERY );
228 Sequence< NumberedSortingInfo > aSortInfo( 1 );
229 NumberedSortingInfo* pInfo = aSortInfo.getArray();
230 pInfo[ 0 ].ColumnIndex = 1;
231 pInfo[ 0 ].Ascending = sal_True;
233 Reference < XAnyCompareFactory > xFactory;
234 Reference< XDynamicResultSet > xDynamicResultSet;
235 xDynamicResultSet = xSRSFac->createSortedDynamicResultSet( xContent, aSortInfo, xFactory );
236 Reference<XResultSet> xResultSet = xDynamicResultSet->getStaticResultSet();
238 Reference<XRow> xRow(xResultSet,UNO_QUERY);
240 String aFilenameExtension = m_pConnection->getExtension();
241 String sThisContentExtension;
242 ODatabaseMetaDataResultSet::ORows aRows;
243 // scan the directory for tables
244 ::rtl::OUString aName;
245 INetURLObject aURL;
246 xResultSet->beforeFirst();
248 sal_Bool bKnowCaseSensivity = sal_False;
249 sal_Bool bCaseSensitiveDir = sal_True;
250 sal_Bool bCheckEnabled = m_pConnection->isCheckEnabled();
252 while(xResultSet->next())
254 aName = xRow->getString(1);
255 aURL.SetSmartProtocol(INET_PROT_FILE);
256 String sUrl = m_pConnection->getURL() + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")) + aName;
257 aURL.SetSmartURL( sUrl );
258 sThisContentExtension = aURL.getExtension();
260 ODatabaseMetaDataResultSet::ORow aRow(3);
261 aRow.reserve(6);
262 sal_Bool bNewRow = sal_False;
264 if ( !bKnowCaseSensivity )
266 bKnowCaseSensivity = sal_True;
267 sal_Int16 nCase = isCaseSensitiveParentFolder( m_pConnection->getURL(), aURL.getName() );
268 switch( nCase )
270 case 1:
271 bCaseSensitiveDir = sal_True;
272 break;
273 case -1:
274 bKnowCaseSensivity = sal_False;
275 /** run through */
276 case 0:
277 bCaseSensitiveDir = sal_False;
279 if ( bKnowCaseSensivity )
281 m_pConnection->setCaseSensitiveExtension( bCaseSensitiveDir, OConnection::GrantAccess() );
282 if ( !bCaseSensitiveDir )
283 aFilenameExtension.ToLowerAscii();
287 if (aFilenameExtension.Len())
289 if ( !bCaseSensitiveDir )
290 sThisContentExtension.ToLowerAscii();
292 if ( sThisContentExtension == aFilenameExtension )
294 aName = aName.replaceAt(aName.getLength()-(aFilenameExtension.Len()+1),aFilenameExtension.Len()+1,::rtl::OUString());
295 sal_Unicode nChar = aName.toChar();
296 if ( match(tableNamePattern,aName.getStr(),'\0') && ( !bCheckEnabled || ( bCheckEnabled && ((nChar < '0' || nChar > '9')))) )
298 aRow.push_back(new ORowSetValueDecorator(aName));
299 bNewRow = sal_True;
303 else // no extension, filter myself
305 sal_Bool bErg = sal_False;
308 if (!aURL.getExtension().getLength())
310 sal_Unicode nChar = aURL.getBase().getStr()[0];
311 if(match(tableNamePattern,aURL.getBase().getStr(),'\0') && ( !bCheckEnabled || ( bCheckEnabled && ((nChar < '0' || nChar > '9')))) )
313 aRow.push_back(new ORowSetValueDecorator(::rtl::OUString(aURL.getBase())));
314 bNewRow = sal_True;
316 break;
318 else if ( ( bErg = xResultSet->next() ) != sal_False )
320 aName = xRow->getString(1);
321 aURL.SetSmartURL(aName);
323 } while (bErg);
325 if(bNewRow)
327 aRow.push_back(new ORowSetValueDecorator(aTable));
328 aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
330 aRows.push_back(aRow);
334 pResult->setRows(aRows);
336 return xRef;
338 // -------------------------------------------------------------------------
339 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxBinaryLiteralLength( ) throw(SQLException, RuntimeException)
341 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxBinaryLiteralLength" );
342 return 0;
344 // -------------------------------------------------------------------------
345 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxRowSize( ) throw(SQLException, RuntimeException)
347 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxRowSize" );
348 return 0;
350 // -------------------------------------------------------------------------
351 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxCatalogNameLength( ) throw(SQLException, RuntimeException)
353 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxCatalogNameLength" );
354 return 0;
356 // -------------------------------------------------------------------------
357 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxCharLiteralLength( ) throw(SQLException, RuntimeException)
359 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxCharLiteralLength" );
360 return STRING_MAXLEN;
362 // -------------------------------------------------------------------------
363 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnNameLength( ) throw(SQLException, RuntimeException)
365 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxColumnNameLength" );
366 return 0;
368 // -------------------------------------------------------------------------
369 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInIndex( ) throw(SQLException, RuntimeException)
371 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxColumnsInIndex" );
372 return 0;
374 // -------------------------------------------------------------------------
375 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxCursorNameLength( ) throw(SQLException, RuntimeException)
377 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxCursorNameLength" );
378 return 0;
380 // -------------------------------------------------------------------------
381 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxConnections( ) throw(SQLException, RuntimeException)
383 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxConnections" );
384 return 0;
386 // -------------------------------------------------------------------------
387 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInTable( ) throw(SQLException, RuntimeException)
389 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxColumnsInTable" );
390 return 0;
392 // -------------------------------------------------------------------------
393 sal_Int32 ODatabaseMetaData::impl_getMaxStatements_throw( )
395 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_getMaxStatements_throw" );
396 return 0;
398 // -------------------------------------------------------------------------
399 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxTableNameLength( ) throw(SQLException, RuntimeException)
401 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxTableNameLength" );
402 return 0;
404 // -------------------------------------------------------------------------
405 sal_Int32 ODatabaseMetaData::impl_getMaxTablesInSelect_throw( )
407 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_getMaxTablesInSelect_throw" );
408 return 1;
410 // -------------------------------------------------------------------------
411 Reference< XResultSet > SAL_CALL ODatabaseMetaData::getTablePrivileges(
412 const Any& /*catalog*/, const ::rtl::OUString& /*schemaPattern*/, const ::rtl::OUString& tableNamePattern ) throw(SQLException, RuntimeException)
414 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getTablePrivileges" );
415 ::osl::MutexGuard aGuard( m_aMutex );
417 ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eTablePrivileges );
418 Reference< XResultSet > xRef = pResult;
419 ODatabaseMetaDataResultSet::ORows aRows;
422 Reference< XTablesSupplier > xTabSup = m_pConnection->createCatalog();
423 if( xTabSup.is())
425 Reference< XNameAccess> xNames = xTabSup->getTables();
426 Sequence< ::rtl::OUString > aNames = xNames->getElementNames();
427 const ::rtl::OUString* pBegin = aNames.getConstArray();
428 const ::rtl::OUString* pEnd = pBegin + aNames.getLength();
429 for(;pBegin != pEnd;++pBegin)
431 if(match(tableNamePattern,pBegin->getStr(),'\0'))
433 static ODatabaseMetaDataResultSet::ORow aRow(8);
435 aRow[2] = new ORowSetValueDecorator(*pBegin);
436 aRow[6] = ODatabaseMetaDataResultSet::getSelectValue();
437 aRow[7] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("NO"));
438 aRows.push_back(aRow);
440 Reference< XPropertySet> xTable;
441 ::cppu::extractInterface(xTable,xNames->getByName(*pBegin));
442 if(xTable.is())
444 Reference<XUnoTunnel> xTunnel(xTable,UNO_QUERY);
445 if(xTunnel.is())
447 OFileTable* pTable = reinterpret_cast< OFileTable* >( xTunnel->getSomething(OFileTable::getUnoTunnelImplementationId()) );
448 if(pTable)
450 if(!pTable->isReadOnly())
452 aRow[6] = ODatabaseMetaDataResultSet::getInsertValue();
453 aRows.push_back(aRow);
454 if(!m_pConnection->showDeleted())
456 aRow[6] = ODatabaseMetaDataResultSet::getDeleteValue();
457 aRows.push_back(aRow);
459 aRow[6] = ODatabaseMetaDataResultSet::getUpdateValue();
460 aRows.push_back(aRow);
461 aRow[6] = ODatabaseMetaDataResultSet::getCreateValue();
462 aRows.push_back(aRow);
463 aRow[6] = ODatabaseMetaDataResultSet::getReadValue();
464 aRows.push_back(aRow);
465 aRow[6] = ODatabaseMetaDataResultSet::getAlterValue();
466 aRows.push_back(aRow);
467 aRow[6] = ODatabaseMetaDataResultSet::getDropValue();
468 aRows.push_back(aRow);
477 pResult->setRows(aRows);
478 return xRef;
480 // -------------------------------------------------------------------------
481 sal_Bool SAL_CALL ODatabaseMetaData::doesMaxRowSizeIncludeBlobs( ) throw(SQLException, RuntimeException)
483 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::doesMaxRowSizeIncludeBlobs" );
484 return sal_True;
486 // -------------------------------------------------------------------------
487 sal_Bool SAL_CALL ODatabaseMetaData::storesLowerCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException)
489 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::storesLowerCaseQuotedIdentifiers" );
490 return sal_False;
492 // -------------------------------------------------------------------------
493 sal_Bool SAL_CALL ODatabaseMetaData::storesLowerCaseIdentifiers( ) throw(SQLException, RuntimeException)
495 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::storesLowerCaseIdentifiers" );
496 return sal_False;
498 // -------------------------------------------------------------------------
499 sal_Bool ODatabaseMetaData::impl_storesMixedCaseQuotedIdentifiers_throw( )
501 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_storesMixedCaseQuotedIdentifiers_throw" );
502 return sal_False;
504 // -------------------------------------------------------------------------
505 sal_Bool SAL_CALL ODatabaseMetaData::storesMixedCaseIdentifiers( ) throw(SQLException, RuntimeException)
507 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::storesMixedCaseIdentifiers" );
508 return sal_False;
510 // -------------------------------------------------------------------------
511 sal_Bool SAL_CALL ODatabaseMetaData::storesUpperCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException)
513 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::storesUpperCaseQuotedIdentifiers" );
514 return sal_False;
516 // -------------------------------------------------------------------------
517 sal_Bool SAL_CALL ODatabaseMetaData::storesUpperCaseIdentifiers( ) throw(SQLException, RuntimeException)
519 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::storesUpperCaseIdentifiers" );
520 return sal_False;
522 // -------------------------------------------------------------------------
523 sal_Bool ODatabaseMetaData::impl_supportsAlterTableWithAddColumn_throw( )
525 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_supportsAlterTableWithAddColumn_throw" );
526 return sal_False;
528 // -------------------------------------------------------------------------
529 sal_Bool ODatabaseMetaData::impl_supportsAlterTableWithDropColumn_throw( )
531 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_supportsAlterTableWithDropColumn_throw" );
532 return sal_False;
534 // -------------------------------------------------------------------------
535 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxIndexLength( ) throw(SQLException, RuntimeException)
537 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxIndexLength" );
538 return 0;
540 // -------------------------------------------------------------------------
541 sal_Bool SAL_CALL ODatabaseMetaData::supportsNonNullableColumns( ) throw(SQLException, RuntimeException)
543 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsNonNullableColumns" );
544 return sal_False;
546 // -------------------------------------------------------------------------
547 ::rtl::OUString SAL_CALL ODatabaseMetaData::getCatalogTerm( ) throw(SQLException, RuntimeException)
549 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getCatalogTerm" );
550 return ::rtl::OUString();
552 // -------------------------------------------------------------------------
553 ::rtl::OUString ODatabaseMetaData::impl_getIdentifierQuoteString_throw( )
555 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_getIdentifierQuoteString_throw" );
556 static const ::rtl::OUString sQuote = ::rtl::OUString::createFromAscii("\"");
557 return sQuote;
559 // -------------------------------------------------------------------------
560 ::rtl::OUString SAL_CALL ODatabaseMetaData::getExtraNameCharacters( ) throw(SQLException, RuntimeException)
562 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getExtraNameCharacters" );
563 return ::rtl::OUString();
565 // -------------------------------------------------------------------------
566 sal_Bool SAL_CALL ODatabaseMetaData::supportsDifferentTableCorrelationNames( ) throw(SQLException, RuntimeException)
568 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsDifferentTableCorrelationNames" );
569 return sal_True;
571 // -------------------------------------------------------------------------
572 sal_Bool ODatabaseMetaData::impl_isCatalogAtStart_throw( )
574 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_isCatalogAtStart_throw" );
575 return sal_True;
577 // -------------------------------------------------------------------------
578 sal_Bool SAL_CALL ODatabaseMetaData::dataDefinitionIgnoredInTransactions( ) throw(SQLException, RuntimeException)
580 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::dataDefinitionIgnoredInTransactions" );
581 return sal_True;
583 // -------------------------------------------------------------------------
584 sal_Bool SAL_CALL ODatabaseMetaData::dataDefinitionCausesTransactionCommit( ) throw(SQLException, RuntimeException)
586 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::dataDefinitionCausesTransactionCommit" );
587 return sal_True;
589 // -------------------------------------------------------------------------
590 sal_Bool SAL_CALL ODatabaseMetaData::supportsDataManipulationTransactionsOnly( ) throw(SQLException, RuntimeException)
592 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsDataManipulationTransactionsOnly" );
593 return sal_False;
595 // -------------------------------------------------------------------------
596 sal_Bool SAL_CALL ODatabaseMetaData::supportsDataDefinitionAndDataManipulationTransactions( ) throw(SQLException, RuntimeException)
598 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsDataDefinitionAndDataManipulationTransactions" );
599 return sal_False;
601 // -------------------------------------------------------------------------
602 sal_Bool SAL_CALL ODatabaseMetaData::supportsPositionedDelete( ) throw(SQLException, RuntimeException)
604 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsPositionedDelete" );
605 return sal_False;
607 // -------------------------------------------------------------------------
608 sal_Bool SAL_CALL ODatabaseMetaData::supportsPositionedUpdate( ) throw(SQLException, RuntimeException)
610 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsPositionedUpdate" );
611 return sal_False;
613 // -------------------------------------------------------------------------
614 sal_Bool SAL_CALL ODatabaseMetaData::supportsOpenStatementsAcrossRollback( ) throw(SQLException, RuntimeException)
616 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsOpenStatementsAcrossRollback" );
617 return sal_False;
619 // -------------------------------------------------------------------------
620 sal_Bool SAL_CALL ODatabaseMetaData::supportsOpenStatementsAcrossCommit( ) throw(SQLException, RuntimeException)
622 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsOpenStatementsAcrossCommit" );
623 return sal_False;
625 // -------------------------------------------------------------------------
626 sal_Bool SAL_CALL ODatabaseMetaData::supportsOpenCursorsAcrossCommit( ) throw(SQLException, RuntimeException)
628 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsOpenCursorsAcrossCommit" );
629 return sal_False;
631 // -------------------------------------------------------------------------
632 sal_Bool SAL_CALL ODatabaseMetaData::supportsOpenCursorsAcrossRollback( ) throw(SQLException, RuntimeException)
634 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsOpenCursorsAcrossRollback" );
635 return sal_False;
637 // -------------------------------------------------------------------------
638 sal_Bool SAL_CALL ODatabaseMetaData::supportsTransactionIsolationLevel( sal_Int32 /*level*/ ) throw(SQLException, RuntimeException)
640 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsTransactionIsolationLevel" );
641 return sal_False;
643 // -------------------------------------------------------------------------
644 sal_Bool ODatabaseMetaData::impl_supportsSchemasInDataManipulation_throw( )
646 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_supportsSchemasInDataManipulation_throw" );
647 return sal_False;
649 // -------------------------------------------------------------------------
650 sal_Bool SAL_CALL ODatabaseMetaData::supportsANSI92FullSQL( ) throw(SQLException, RuntimeException)
652 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsANSI92FullSQL" );
653 return sal_False;
655 // -------------------------------------------------------------------------
656 sal_Bool SAL_CALL ODatabaseMetaData::supportsANSI92EntryLevelSQL( ) throw(SQLException, RuntimeException)
658 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsANSI92EntryLevelSQL" );
659 return sal_False;
661 // -------------------------------------------------------------------------
662 sal_Bool SAL_CALL ODatabaseMetaData::supportsIntegrityEnhancementFacility( ) throw(SQLException, RuntimeException)
664 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsIntegrityEnhancementFacility" );
665 return sal_False;
667 // -------------------------------------------------------------------------
668 sal_Bool SAL_CALL ODatabaseMetaData::supportsSchemasInIndexDefinitions( ) throw(SQLException, RuntimeException)
670 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsSchemasInIndexDefinitions" );
671 return sal_False;
673 // -------------------------------------------------------------------------
674 sal_Bool ODatabaseMetaData::impl_supportsSchemasInTableDefinitions_throw( )
676 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_supportsSchemasInTableDefinitions_throw" );
677 return sal_False;
679 // -------------------------------------------------------------------------
680 sal_Bool ODatabaseMetaData::impl_supportsCatalogsInTableDefinitions_throw( )
682 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_supportsCatalogsInTableDefinitions_throw" );
683 return sal_False;
685 // -------------------------------------------------------------------------
686 sal_Bool SAL_CALL ODatabaseMetaData::supportsCatalogsInIndexDefinitions( ) throw(SQLException, RuntimeException)
688 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsCatalogsInIndexDefinitions" );
689 return sal_False;
691 // -------------------------------------------------------------------------
692 sal_Bool ODatabaseMetaData::impl_supportsCatalogsInDataManipulation_throw( )
694 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_supportsCatalogsInDataManipulation_throw" );
695 return sal_False;
697 // -------------------------------------------------------------------------
698 sal_Bool SAL_CALL ODatabaseMetaData::supportsOuterJoins( ) throw(SQLException, RuntimeException)
700 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsOuterJoins" );
701 return sal_False;
703 // -------------------------------------------------------------------------
704 Reference< XResultSet > SAL_CALL ODatabaseMetaData::getTableTypes( ) throw(SQLException, RuntimeException)
706 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getTableTypes" );
707 ::osl::MutexGuard aGuard( m_aMutex );
709 ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eTableTypes );
710 Reference< XResultSet > xRef = pResult;
711 static ODatabaseMetaDataResultSet::ORows aRows;
712 if(aRows.empty())
714 ODatabaseMetaDataResultSet::ORow aRow;
715 aRow.push_back(ODatabaseMetaDataResultSet::getEmptyValue());
716 aRow.push_back(new ORowSetValueDecorator(::rtl::OUString::createFromAscii("TABLE")));
717 aRows.push_back(aRow);
719 pResult->setRows(aRows);
720 return xRef;
722 // -------------------------------------------------------------------------
723 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxStatementLength( ) throw(SQLException, RuntimeException)
725 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxStatementLength" );
726 return 0;
728 // -------------------------------------------------------------------------
729 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxProcedureNameLength( ) throw(SQLException, RuntimeException)
731 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxProcedureNameLength" );
732 return 0;
734 // -------------------------------------------------------------------------
735 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxSchemaNameLength( ) throw(SQLException, RuntimeException)
737 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxSchemaNameLength" );
738 return 0;
740 // -------------------------------------------------------------------------
741 sal_Bool SAL_CALL ODatabaseMetaData::supportsTransactions( ) throw(SQLException, RuntimeException)
743 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsTransactions" );
744 return sal_False;
746 // -------------------------------------------------------------------------
747 sal_Bool SAL_CALL ODatabaseMetaData::allProceduresAreCallable( ) throw(SQLException, RuntimeException)
749 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::allProceduresAreCallable" );
750 return sal_False;
752 // -------------------------------------------------------------------------
753 sal_Bool SAL_CALL ODatabaseMetaData::supportsStoredProcedures( ) throw(SQLException, RuntimeException)
755 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsStoredProcedures" );
756 return sal_False;
758 // -------------------------------------------------------------------------
759 sal_Bool SAL_CALL ODatabaseMetaData::supportsSelectForUpdate( ) throw(SQLException, RuntimeException)
761 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsSelectForUpdate" );
762 return sal_False;
764 // -------------------------------------------------------------------------
765 sal_Bool SAL_CALL ODatabaseMetaData::allTablesAreSelectable( ) throw(SQLException, RuntimeException)
767 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::allTablesAreSelectable" );
768 return sal_True;
770 // -------------------------------------------------------------------------
771 sal_Bool SAL_CALL ODatabaseMetaData::isReadOnly( ) throw(SQLException, RuntimeException)
773 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::isReadOnly" );
774 return sal_True;
776 // -------------------------------------------------------------------------
777 sal_Bool SAL_CALL ODatabaseMetaData::usesLocalFiles( ) throw(SQLException, RuntimeException)
779 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::usesLocalFiles" );
780 return sal_True;
782 // -------------------------------------------------------------------------
783 sal_Bool SAL_CALL ODatabaseMetaData::usesLocalFilePerTable( ) throw(SQLException, RuntimeException)
785 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::usesLocalFilePerTable" );
786 return sal_True;
788 // -------------------------------------------------------------------------
789 sal_Bool SAL_CALL ODatabaseMetaData::supportsTypeConversion( ) throw(SQLException, RuntimeException)
791 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsTypeConversion" );
792 return sal_False;
794 // -------------------------------------------------------------------------
795 sal_Bool SAL_CALL ODatabaseMetaData::nullPlusNonNullIsNull( ) throw(SQLException, RuntimeException)
797 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::nullPlusNonNullIsNull" );
798 return sal_True;
800 // -------------------------------------------------------------------------
801 sal_Bool SAL_CALL ODatabaseMetaData::supportsColumnAliasing( ) throw(SQLException, RuntimeException)
803 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsColumnAliasing" );
804 return sal_True;
806 // -------------------------------------------------------------------------
807 sal_Bool SAL_CALL ODatabaseMetaData::supportsTableCorrelationNames( ) throw(SQLException, RuntimeException)
809 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsTableCorrelationNames" );
810 return sal_True;
812 // -------------------------------------------------------------------------
813 sal_Bool SAL_CALL ODatabaseMetaData::supportsConvert( sal_Int32 /*fromType*/, sal_Int32 /*toType*/ ) throw(SQLException, RuntimeException)
815 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsConvert" );
816 return sal_False;
818 // -------------------------------------------------------------------------
819 sal_Bool SAL_CALL ODatabaseMetaData::supportsExpressionsInOrderBy( ) throw(SQLException, RuntimeException)
821 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsExpressionsInOrderBy" );
822 return sal_False;
824 // -------------------------------------------------------------------------
825 sal_Bool SAL_CALL ODatabaseMetaData::supportsGroupBy( ) throw(SQLException, RuntimeException)
827 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsGroupBy" );
828 return sal_False;
830 // -------------------------------------------------------------------------
831 sal_Bool SAL_CALL ODatabaseMetaData::supportsGroupByBeyondSelect( ) throw(SQLException, RuntimeException)
833 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsGroupByBeyondSelect" );
834 return sal_False;
836 // -------------------------------------------------------------------------
837 sal_Bool SAL_CALL ODatabaseMetaData::supportsGroupByUnrelated( ) throw(SQLException, RuntimeException)
839 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsGroupByUnrelated" );
840 return sal_False;
842 // -------------------------------------------------------------------------
843 sal_Bool SAL_CALL ODatabaseMetaData::supportsMultipleTransactions( ) throw(SQLException, RuntimeException)
845 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsMultipleTransactions" );
846 return sal_False;
848 // -------------------------------------------------------------------------
849 sal_Bool SAL_CALL ODatabaseMetaData::supportsMultipleResultSets( ) throw(SQLException, RuntimeException)
851 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsMultipleResultSets" );
852 return sal_False;
854 // -------------------------------------------------------------------------
855 sal_Bool SAL_CALL ODatabaseMetaData::supportsLikeEscapeClause( ) throw(SQLException, RuntimeException)
857 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsLikeEscapeClause" );
858 return sal_False;
860 // -------------------------------------------------------------------------
861 sal_Bool SAL_CALL ODatabaseMetaData::supportsOrderByUnrelated( ) throw(SQLException, RuntimeException)
863 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsOrderByUnrelated" );
864 return sal_True;
866 // -------------------------------------------------------------------------
867 sal_Bool SAL_CALL ODatabaseMetaData::supportsUnion( ) throw(SQLException, RuntimeException)
869 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsUnion" );
870 return sal_False;
872 // -------------------------------------------------------------------------
873 sal_Bool SAL_CALL ODatabaseMetaData::supportsUnionAll( ) throw(SQLException, RuntimeException)
875 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsUnionAll" );
876 return sal_False;
878 // -------------------------------------------------------------------------
879 sal_Bool SAL_CALL ODatabaseMetaData::supportsMixedCaseIdentifiers( ) throw(SQLException, RuntimeException)
881 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsMixedCaseIdentifiers" );
882 return sal_True;
884 // -------------------------------------------------------------------------
885 sal_Bool ODatabaseMetaData::impl_supportsMixedCaseQuotedIdentifiers_throw( )
887 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::impl_supportsMixedCaseQuotedIdentifiers_throw" );
888 return sal_False;
890 // -------------------------------------------------------------------------
891 sal_Bool SAL_CALL ODatabaseMetaData::nullsAreSortedAtEnd( ) throw(SQLException, RuntimeException)
893 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::nullsAreSortedAtEnd" );
894 return sal_False;
896 // -------------------------------------------------------------------------
897 sal_Bool SAL_CALL ODatabaseMetaData::nullsAreSortedAtStart( ) throw(SQLException, RuntimeException)
899 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::nullsAreSortedAtStart" );
900 return sal_True;
902 // -------------------------------------------------------------------------
903 sal_Bool SAL_CALL ODatabaseMetaData::nullsAreSortedHigh( ) throw(SQLException, RuntimeException)
905 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::nullsAreSortedHigh" );
906 return sal_False;
908 // -------------------------------------------------------------------------
909 sal_Bool SAL_CALL ODatabaseMetaData::nullsAreSortedLow( ) throw(SQLException, RuntimeException)
911 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::nullsAreSortedLow" );
912 return sal_True;
914 // -------------------------------------------------------------------------
915 sal_Bool SAL_CALL ODatabaseMetaData::supportsSchemasInProcedureCalls( ) throw(SQLException, RuntimeException)
917 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsSchemasInProcedureCalls" );
918 return sal_False;
920 // -------------------------------------------------------------------------
921 sal_Bool SAL_CALL ODatabaseMetaData::supportsSchemasInPrivilegeDefinitions( ) throw(SQLException, RuntimeException)
923 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsSchemasInPrivilegeDefinitions" );
924 return sal_False;
926 // -------------------------------------------------------------------------
927 sal_Bool SAL_CALL ODatabaseMetaData::supportsCatalogsInProcedureCalls( ) throw(SQLException, RuntimeException)
929 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsCatalogsInProcedureCalls" );
930 return sal_False;
932 // -------------------------------------------------------------------------
933 sal_Bool SAL_CALL ODatabaseMetaData::supportsCatalogsInPrivilegeDefinitions( ) throw(SQLException, RuntimeException)
935 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsCatalogsInPrivilegeDefinitions" );
936 return sal_False;
938 // -------------------------------------------------------------------------
939 sal_Bool SAL_CALL ODatabaseMetaData::supportsCorrelatedSubqueries( ) throw(SQLException, RuntimeException)
941 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsCorrelatedSubqueries" );
942 return sal_False;
944 // -------------------------------------------------------------------------
945 sal_Bool SAL_CALL ODatabaseMetaData::supportsSubqueriesInComparisons( ) throw(SQLException, RuntimeException)
947 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsSubqueriesInComparisons" );
948 return sal_False;
950 // -------------------------------------------------------------------------
951 sal_Bool SAL_CALL ODatabaseMetaData::supportsSubqueriesInExists( ) throw(SQLException, RuntimeException)
953 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsSubqueriesInExists" );
954 return sal_False;
956 // -------------------------------------------------------------------------
957 sal_Bool SAL_CALL ODatabaseMetaData::supportsSubqueriesInIns( ) throw(SQLException, RuntimeException)
959 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsSubqueriesInIns" );
960 return sal_False;
962 // -------------------------------------------------------------------------
963 sal_Bool SAL_CALL ODatabaseMetaData::supportsSubqueriesInQuantifieds( ) throw(SQLException, RuntimeException)
965 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsSubqueriesInQuantifieds" );
966 return sal_False;
968 // -------------------------------------------------------------------------
969 sal_Bool SAL_CALL ODatabaseMetaData::supportsANSI92IntermediateSQL( ) throw(SQLException, RuntimeException)
971 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsANSI92IntermediateSQL" );
972 return sal_False;
974 // -------------------------------------------------------------------------
975 ::rtl::OUString SAL_CALL ODatabaseMetaData::getURL( ) throw(SQLException, RuntimeException)
977 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getURL" );
978 static const ::rtl::OUString aValue = ::rtl::OUString::createFromAscii("sdbc:file:");
979 return aValue;
981 // -------------------------------------------------------------------------
982 ::rtl::OUString SAL_CALL ODatabaseMetaData::getUserName( ) throw(SQLException, RuntimeException)
984 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getUserName" );
985 return ::rtl::OUString();
987 // -------------------------------------------------------------------------
988 ::rtl::OUString SAL_CALL ODatabaseMetaData::getDriverName( ) throw(SQLException, RuntimeException)
990 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getDriverName" );
991 return ::rtl::OUString();
993 // -------------------------------------------------------------------------
994 ::rtl::OUString SAL_CALL ODatabaseMetaData::getDriverVersion( ) throw(SQLException, RuntimeException)
996 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getDriverVersion" );
997 return ::rtl::OUString::valueOf((sal_Int32)1);
999 // -------------------------------------------------------------------------
1000 ::rtl::OUString SAL_CALL ODatabaseMetaData::getDatabaseProductVersion( ) throw(SQLException, RuntimeException)
1002 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getDatabaseProductVersion" );
1003 return ::rtl::OUString::valueOf((sal_Int32)0);
1005 // -------------------------------------------------------------------------
1006 ::rtl::OUString SAL_CALL ODatabaseMetaData::getDatabaseProductName( ) throw(SQLException, RuntimeException)
1008 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getDatabaseProductName" );
1009 return ::rtl::OUString();
1011 // -------------------------------------------------------------------------
1012 ::rtl::OUString SAL_CALL ODatabaseMetaData::getProcedureTerm( ) throw(SQLException, RuntimeException)
1014 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getProcedureTerm" );
1015 return ::rtl::OUString();
1017 // -------------------------------------------------------------------------
1018 ::rtl::OUString SAL_CALL ODatabaseMetaData::getSchemaTerm( ) throw(SQLException, RuntimeException)
1020 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getSchemaTerm" );
1021 return ::rtl::OUString();
1023 // -------------------------------------------------------------------------
1024 sal_Int32 SAL_CALL ODatabaseMetaData::getDriverMajorVersion( ) throw(RuntimeException)
1026 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getDriverMajorVersion" );
1027 return 0;
1029 // -------------------------------------------------------------------------
1030 sal_Int32 SAL_CALL ODatabaseMetaData::getDefaultTransactionIsolation( ) throw(SQLException, RuntimeException)
1032 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getDefaultTransactionIsolation" );
1033 return 0;
1035 // -------------------------------------------------------------------------
1036 sal_Int32 SAL_CALL ODatabaseMetaData::getDriverMinorVersion( ) throw(RuntimeException)
1038 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getDriverMinorVersion" );
1039 return 0;
1041 // -------------------------------------------------------------------------
1042 ::rtl::OUString SAL_CALL ODatabaseMetaData::getSQLKeywords( ) throw(SQLException, RuntimeException)
1044 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getSQLKeywords" );
1045 return ::rtl::OUString();
1047 // -------------------------------------------------------------------------
1048 ::rtl::OUString SAL_CALL ODatabaseMetaData::getSearchStringEscape( ) throw(SQLException, RuntimeException)
1050 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getSearchStringEscape" );
1051 return ::rtl::OUString();
1053 // -------------------------------------------------------------------------
1054 ::rtl::OUString SAL_CALL ODatabaseMetaData::getStringFunctions( ) throw(SQLException, RuntimeException)
1056 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getStringFunctions" );
1057 return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UCASE,LCASE,ASCII,LENGTH,OCTET_LENGTH,CHAR_LENGTH,CHARACTER_LENGTH,CHAR,CONCAT,LOCATE,SUBSTRING,LTRIM,RTRIM,SPACE,REPLACE,REPEAT,INSERT,LEFT,RIGHT"));
1059 // -------------------------------------------------------------------------
1060 ::rtl::OUString SAL_CALL ODatabaseMetaData::getTimeDateFunctions( ) throw(SQLException, RuntimeException)
1062 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getTimeDateFunctions" );
1063 return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DAYOFWEEK,DAYOFMONTH,DAYOFYEAR,MONTH,DAYNAME,MONTHNAME,QUARTER,WEEK,YEAR,HOUR,MINUTE,SECOND,CURDATE,CURTIME,NOW"));
1065 // -------------------------------------------------------------------------
1066 ::rtl::OUString SAL_CALL ODatabaseMetaData::getSystemFunctions( ) throw(SQLException, RuntimeException)
1068 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getSystemFunctions" );
1069 return ::rtl::OUString();
1071 // -------------------------------------------------------------------------
1072 ::rtl::OUString SAL_CALL ODatabaseMetaData::getNumericFunctions( ) throw(SQLException, RuntimeException)
1074 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getNumericFunctions" );
1075 return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ABS,SIGN,MOD,FLOOR,CEILING,ROUND,EXP,LN,LOG,LOG10,POWER,SQRT,PI,COS,SIN,TAN,ACOS,ASIN,ATAN,ATAN2,DEGREES,RADIANS"));
1077 // -------------------------------------------------------------------------
1078 sal_Bool SAL_CALL ODatabaseMetaData::supportsExtendedSQLGrammar( ) throw(SQLException, RuntimeException)
1080 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsExtendedSQLGrammar" );
1081 return sal_False;
1083 // -------------------------------------------------------------------------
1084 sal_Bool SAL_CALL ODatabaseMetaData::supportsCoreSQLGrammar( ) throw(SQLException, RuntimeException)
1086 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsCoreSQLGrammar" );
1087 return sal_False;
1089 // -------------------------------------------------------------------------
1090 sal_Bool SAL_CALL ODatabaseMetaData::supportsMinimumSQLGrammar( ) throw(SQLException, RuntimeException)
1092 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsMinimumSQLGrammar" );
1093 return sal_True;
1095 // -------------------------------------------------------------------------
1096 sal_Bool SAL_CALL ODatabaseMetaData::supportsFullOuterJoins( ) throw(SQLException, RuntimeException)
1098 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsFullOuterJoins" );
1099 return sal_False;
1101 // -------------------------------------------------------------------------
1102 sal_Bool SAL_CALL ODatabaseMetaData::supportsLimitedOuterJoins( ) throw(SQLException, RuntimeException)
1104 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsLimitedOuterJoins" );
1105 return sal_False;
1107 // -------------------------------------------------------------------------
1108 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInGroupBy( ) throw(SQLException, RuntimeException)
1110 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxColumnsInGroupBy" );
1111 return 0;
1113 // -------------------------------------------------------------------------
1114 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInOrderBy( ) throw(SQLException, RuntimeException)
1116 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxColumnsInOrderBy" );
1117 return 0;
1119 // -------------------------------------------------------------------------
1120 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInSelect( ) throw(SQLException, RuntimeException)
1122 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxColumnsInSelect" );
1123 return 0;
1125 // -------------------------------------------------------------------------
1126 sal_Int32 SAL_CALL ODatabaseMetaData::getMaxUserNameLength( ) throw(SQLException, RuntimeException)
1128 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getMaxUserNameLength" );
1129 return 0;
1131 // -------------------------------------------------------------------------
1132 sal_Bool SAL_CALL ODatabaseMetaData::supportsResultSetType( sal_Int32 setType ) throw(SQLException, RuntimeException)
1134 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsResultSetType" );
1135 switch(setType)
1137 case ResultSetType::FORWARD_ONLY:
1138 return sal_True;
1139 case ResultSetType::SCROLL_INSENSITIVE:
1140 case ResultSetType::SCROLL_SENSITIVE:
1141 break;
1143 return sal_False;
1145 // -------------------------------------------------------------------------
1146 sal_Bool SAL_CALL ODatabaseMetaData::supportsResultSetConcurrency( sal_Int32 setType, sal_Int32 /*concurrency*/ ) throw(SQLException, RuntimeException)
1148 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsResultSetConcurrency" );
1149 switch(setType)
1151 case ResultSetType::FORWARD_ONLY:
1152 return sal_True;
1153 case ResultSetType::SCROLL_INSENSITIVE:
1154 case ResultSetType::SCROLL_SENSITIVE:
1155 break;
1157 return sal_False;
1159 // -------------------------------------------------------------------------
1160 sal_Bool SAL_CALL ODatabaseMetaData::ownUpdatesAreVisible( sal_Int32 /*setType*/ ) throw(SQLException, RuntimeException)
1162 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::ownUpdatesAreVisible" );
1163 return sal_True;
1165 // -------------------------------------------------------------------------
1166 sal_Bool SAL_CALL ODatabaseMetaData::ownDeletesAreVisible( sal_Int32 /*setType*/ ) throw(SQLException, RuntimeException)
1168 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::ownDeletesAreVisible" );
1169 return sal_True;
1171 // -------------------------------------------------------------------------
1172 sal_Bool SAL_CALL ODatabaseMetaData::ownInsertsAreVisible( sal_Int32 /*setType*/ ) throw(SQLException, RuntimeException)
1174 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::ownInsertsAreVisible" );
1175 return sal_True;
1177 // -------------------------------------------------------------------------
1178 sal_Bool SAL_CALL ODatabaseMetaData::othersUpdatesAreVisible( sal_Int32 /*setType*/ ) throw(SQLException, RuntimeException)
1180 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::othersUpdatesAreVisible" );
1181 return sal_True;
1183 // -------------------------------------------------------------------------
1184 sal_Bool SAL_CALL ODatabaseMetaData::othersDeletesAreVisible( sal_Int32 /*setType*/ ) throw(SQLException, RuntimeException)
1186 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::othersDeletesAreVisible" );
1187 return sal_True;
1189 // -------------------------------------------------------------------------
1190 sal_Bool SAL_CALL ODatabaseMetaData::othersInsertsAreVisible( sal_Int32 /*setType*/ ) throw(SQLException, RuntimeException)
1192 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::othersInsertsAreVisible" );
1193 return sal_True;
1195 // -------------------------------------------------------------------------
1196 sal_Bool SAL_CALL ODatabaseMetaData::updatesAreDetected( sal_Int32 /*setType*/ ) throw(SQLException, RuntimeException)
1198 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::updatesAreDetected" );
1199 return sal_False;
1201 // -------------------------------------------------------------------------
1202 sal_Bool SAL_CALL ODatabaseMetaData::deletesAreDetected( sal_Int32 /*setType*/ ) throw(SQLException, RuntimeException)
1204 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::deletesAreDetected" );
1205 return sal_False;
1207 // -------------------------------------------------------------------------
1208 sal_Bool SAL_CALL ODatabaseMetaData::insertsAreDetected( sal_Int32 /*setType*/ ) throw(SQLException, RuntimeException)
1210 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::insertsAreDetected" );
1211 return sal_False;
1213 // -------------------------------------------------------------------------
1214 sal_Bool SAL_CALL ODatabaseMetaData::supportsBatchUpdates( ) throw(SQLException, RuntimeException)
1216 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::supportsBatchUpdates" );
1217 return sal_False;
1219 // -------------------------------------------------------------------------
1220 Reference< XResultSet > SAL_CALL ODatabaseMetaData::getUDTs( const Any& /*catalog*/, const ::rtl::OUString& /*schemaPattern*/, const ::rtl::OUString& /*typeNamePattern*/, const Sequence< sal_Int32 >& /*types*/ ) throw(SQLException, RuntimeException)
1222 RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "file", "Ocke.Janssen@sun.com", "ODatabaseMetaData::getUDTs" );
1223 return NULL;