merge the formfield patch from ooo-build
[ooovba.git] / connectivity / source / drivers / macab / MacabDatabaseMetaData.cxx
blob95cf98cbd432b53c35b471668ef7fd189dfe8b37
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: MacabDatabaseMetaData.cxx,v $
10 * $Revision: 1.4 $
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"
34 #include "MacabDatabaseMetaData.hxx"
35 #include "MacabAddressBook.hxx"
36 #include "MacabHeader.hxx"
37 #include "MacabGroup.hxx"
38 #include "macabutilities.hxx"
40 #ifndef CONNECTIVITY_MACAB_DRIVER_HXX_
41 #include "MacabDriver.hxx"
42 #endif
43 #include "FDatabaseMetaDataResultSet.hxx"
44 #include "OTypeInfo.hxx"
45 #include <com/sun/star/sdbc/ColumnValue.hpp>
46 #include <com/sun/star/sdbc/ResultSetType.hpp>
47 #include <com/sun/star/sdbc/TransactionIsolation.hpp>
49 #include <vector>
51 using namespace connectivity::macab;
52 using namespace com::sun::star::uno;
53 using namespace com::sun::star::lang;
54 using namespace com::sun::star::beans;
55 using namespace com::sun::star::sdbc;
57 MacabDatabaseMetaData::MacabDatabaseMetaData(MacabConnection* _pCon)
58 : m_xConnection(_pCon),
59 m_bUseCatalog(sal_True)
61 OSL_ENSURE(_pCon,"MacabDatabaseMetaData::MacabDatabaseMetaData: No connection set!");
63 osl_incrementInterlockedCount( &m_refCount );
64 m_bUseCatalog = !(usesLocalFiles() || usesLocalFilePerTable());
65 osl_decrementInterlockedCount( &m_refCount );
67 // -------------------------------------------------------------------------
68 MacabDatabaseMetaData::~MacabDatabaseMetaData()
71 // -------------------------------------------------------------------------
72 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getCatalogSeparator( ) throw(SQLException, RuntimeException)
74 ::rtl::OUString aVal;
75 if (m_bUseCatalog)
76 { // do some special here for you database
79 return aVal;
81 // -------------------------------------------------------------------------
82 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxBinaryLiteralLength( ) throw(SQLException, RuntimeException)
84 sal_Int32 nValue = 0; // 0 means no limit
85 return nValue;
87 // -------------------------------------------------------------------------
88 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxRowSize( ) throw(SQLException, RuntimeException)
90 sal_Int32 nValue = 0; // 0 means no limit
91 return nValue;
93 // -------------------------------------------------------------------------
94 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxCatalogNameLength( ) throw(SQLException, RuntimeException)
96 sal_Int32 nValue = 0; // 0 means no limit
97 return nValue;
99 // -------------------------------------------------------------------------
100 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxCharLiteralLength( ) throw(SQLException, RuntimeException)
102 sal_Int32 nValue = 0; // 0 means no limit
103 return nValue;
105 // -------------------------------------------------------------------------
106 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxColumnNameLength( ) throw(SQLException, RuntimeException)
108 sal_Int32 nValue = 0; // 0 means no limit
109 return nValue;
111 // -------------------------------------------------------------------------
112 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxColumnsInIndex( ) throw(SQLException, RuntimeException)
114 sal_Int32 nValue = 0; // 0 means no limit
115 return nValue;
117 // -------------------------------------------------------------------------
118 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxCursorNameLength( ) throw(SQLException, RuntimeException)
120 sal_Int32 nValue = 0; // 0 means no limit
121 return nValue;
123 // -------------------------------------------------------------------------
124 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxConnections( ) throw(SQLException, RuntimeException)
126 sal_Int32 nValue = 0; // 0 means no limit
127 return nValue;
129 // -------------------------------------------------------------------------
130 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxColumnsInTable( ) throw(SQLException, RuntimeException)
132 sal_Int32 nValue = 0; // 0 means no limit
133 return nValue;
135 // -------------------------------------------------------------------------
136 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxStatementLength( ) throw(SQLException, RuntimeException)
138 sal_Int32 nValue = 0; // 0 means no limit
139 return nValue;
141 // -------------------------------------------------------------------------
142 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxTableNameLength( ) throw(SQLException, RuntimeException)
144 sal_Int32 nValue = 0; // 0 means no limit
145 return nValue;
147 // -------------------------------------------------------------------------
148 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxTablesInSelect( ) throw(SQLException, RuntimeException)
150 // MaxTablesInSelect describes how many tables can participate in the FROM part of a given SELECT statement,
151 // currently, the resultset/statement implementations can cope with one table only
152 sal_Int32 nValue = 1;
153 return nValue;
155 // -------------------------------------------------------------------------
156 sal_Bool SAL_CALL MacabDatabaseMetaData::doesMaxRowSizeIncludeBlobs( ) throw(SQLException, RuntimeException)
158 return sal_False;
160 // -------------------------------------------------------------------------
161 sal_Bool SAL_CALL MacabDatabaseMetaData::storesLowerCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException)
163 return sal_False;
165 // -------------------------------------------------------------------------
166 sal_Bool SAL_CALL MacabDatabaseMetaData::storesLowerCaseIdentifiers( ) throw(SQLException, RuntimeException)
168 return sal_False;
170 // -------------------------------------------------------------------------
171 sal_Bool SAL_CALL MacabDatabaseMetaData::storesMixedCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException)
173 return sal_False;
175 // -------------------------------------------------------------------------
176 sal_Bool SAL_CALL MacabDatabaseMetaData::storesMixedCaseIdentifiers( ) throw(SQLException, RuntimeException)
178 return sal_False;
180 // -------------------------------------------------------------------------
181 sal_Bool SAL_CALL MacabDatabaseMetaData::storesUpperCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException)
183 return sal_False;
185 // -------------------------------------------------------------------------
186 sal_Bool SAL_CALL MacabDatabaseMetaData::storesUpperCaseIdentifiers( ) throw(SQLException, RuntimeException)
188 return sal_False;
190 // -------------------------------------------------------------------------
191 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsAlterTableWithAddColumn( ) throw(SQLException, RuntimeException)
193 return sal_False;
195 // -------------------------------------------------------------------------
196 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsAlterTableWithDropColumn( ) throw(SQLException, RuntimeException)
198 return sal_False;
200 // -------------------------------------------------------------------------
201 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxIndexLength( ) throw(SQLException, RuntimeException)
203 sal_Int32 nValue = 0; // 0 means no limit
204 return nValue;
206 // -------------------------------------------------------------------------
207 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsNonNullableColumns( ) throw(SQLException, RuntimeException)
209 return sal_False;
211 // -------------------------------------------------------------------------
212 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getCatalogTerm( ) throw(SQLException, RuntimeException)
214 ::rtl::OUString aVal;
215 if (m_bUseCatalog)
218 return aVal;
220 // -------------------------------------------------------------------------
221 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getIdentifierQuoteString( ) throw(SQLException, RuntimeException)
223 // normally this is "
224 ::rtl::OUString aVal = ::rtl::OUString::createFromAscii("\"");
225 return aVal;
227 // -------------------------------------------------------------------------
228 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getExtraNameCharacters( ) throw(SQLException, RuntimeException)
230 ::rtl::OUString aVal;
231 return aVal;
233 // -------------------------------------------------------------------------
234 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsDifferentTableCorrelationNames( ) throw(SQLException, RuntimeException)
236 return sal_False;
238 // -------------------------------------------------------------------------
239 sal_Bool SAL_CALL MacabDatabaseMetaData::isCatalogAtStart( ) throw(SQLException, RuntimeException)
241 sal_Bool bValue = sal_False;
242 if (m_bUseCatalog)
245 return bValue;
247 // -------------------------------------------------------------------------
248 sal_Bool SAL_CALL MacabDatabaseMetaData::dataDefinitionIgnoredInTransactions( ) throw(SQLException, RuntimeException)
250 return sal_True;
252 // -------------------------------------------------------------------------
253 sal_Bool SAL_CALL MacabDatabaseMetaData::dataDefinitionCausesTransactionCommit( ) throw(SQLException, RuntimeException)
255 return sal_True;
257 // -------------------------------------------------------------------------
258 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsDataManipulationTransactionsOnly( ) throw(SQLException, RuntimeException)
260 return sal_True;
262 // -------------------------------------------------------------------------
263 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsDataDefinitionAndDataManipulationTransactions( ) throw(SQLException, RuntimeException)
265 return sal_True;
267 // -------------------------------------------------------------------------
268 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsPositionedDelete( ) throw(SQLException, RuntimeException)
270 return sal_False;
272 // -------------------------------------------------------------------------
273 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsPositionedUpdate( ) throw(SQLException, RuntimeException)
275 return sal_False;
277 // -------------------------------------------------------------------------
278 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsOpenStatementsAcrossRollback( ) throw(SQLException, RuntimeException)
280 return sal_False;
282 // -------------------------------------------------------------------------
283 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsOpenStatementsAcrossCommit( ) throw(SQLException, RuntimeException)
285 return sal_False;
287 // -------------------------------------------------------------------------
288 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsOpenCursorsAcrossCommit( ) throw(SQLException, RuntimeException)
290 return sal_False;
292 // -------------------------------------------------------------------------
293 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsOpenCursorsAcrossRollback( ) throw(SQLException, RuntimeException)
295 return sal_False;
297 // -------------------------------------------------------------------------
298 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsTransactionIsolationLevel( sal_Int32 ) throw(SQLException, RuntimeException)
300 return sal_False;
302 // -------------------------------------------------------------------------
303 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSchemasInDataManipulation( ) throw(SQLException, RuntimeException)
305 return sal_False;
307 // -------------------------------------------------------------------------
308 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsANSI92FullSQL( ) throw(SQLException, RuntimeException)
310 return sal_False;
312 // -------------------------------------------------------------------------
313 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsANSI92EntryLevelSQL( ) throw(SQLException, RuntimeException)
315 return sal_True; // should be supported at least
317 // -------------------------------------------------------------------------
318 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsIntegrityEnhancementFacility( ) throw(SQLException, RuntimeException)
320 return sal_False;
322 // -------------------------------------------------------------------------
323 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSchemasInIndexDefinitions( ) throw(SQLException, RuntimeException)
325 return sal_False;
327 // -------------------------------------------------------------------------
328 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSchemasInTableDefinitions( ) throw(SQLException, RuntimeException)
330 return sal_False;
332 // -------------------------------------------------------------------------
333 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsCatalogsInTableDefinitions( ) throw(SQLException, RuntimeException)
335 return sal_False;
337 // -------------------------------------------------------------------------
338 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsCatalogsInIndexDefinitions( ) throw(SQLException, RuntimeException)
340 return sal_False;
342 // -------------------------------------------------------------------------
343 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsCatalogsInDataManipulation( ) throw(SQLException, RuntimeException)
345 return sal_False;
347 // -------------------------------------------------------------------------
348 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsOuterJoins( ) throw(SQLException, RuntimeException)
350 return sal_False;
352 // -------------------------------------------------------------------------
353 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxStatements( ) throw(SQLException, RuntimeException)
355 sal_Int32 nValue = 0; // 0 means no limit
356 return nValue;
358 // -------------------------------------------------------------------------
359 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxProcedureNameLength( ) throw(SQLException, RuntimeException)
361 sal_Int32 nValue = 0; // 0 means no limit
362 return nValue;
364 // -------------------------------------------------------------------------
365 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxSchemaNameLength( ) throw(SQLException, RuntimeException)
367 sal_Int32 nValue = 0; // 0 means no limit
368 return nValue;
370 // -------------------------------------------------------------------------
371 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsTransactions( ) throw(SQLException, RuntimeException)
373 return sal_False;
375 // -------------------------------------------------------------------------
376 sal_Bool SAL_CALL MacabDatabaseMetaData::allProceduresAreCallable( ) throw(SQLException, RuntimeException)
378 return sal_False;
380 // -------------------------------------------------------------------------
381 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsStoredProcedures( ) throw(SQLException, RuntimeException)
383 return sal_False;
385 // -------------------------------------------------------------------------
386 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSelectForUpdate( ) throw(SQLException, RuntimeException)
388 return sal_False;
390 // -------------------------------------------------------------------------
391 sal_Bool SAL_CALL MacabDatabaseMetaData::allTablesAreSelectable( ) throw(SQLException, RuntimeException)
393 return sal_False;
395 // -------------------------------------------------------------------------
396 sal_Bool SAL_CALL MacabDatabaseMetaData::isReadOnly( ) throw(SQLException, RuntimeException)
398 // for the moment, we have read-only addresses, but this might change in the future
399 return sal_True;
401 // -------------------------------------------------------------------------
402 sal_Bool SAL_CALL MacabDatabaseMetaData::usesLocalFiles( ) throw(SQLException, RuntimeException)
404 return sal_False;
406 // -------------------------------------------------------------------------
407 sal_Bool SAL_CALL MacabDatabaseMetaData::usesLocalFilePerTable( ) throw(SQLException, RuntimeException)
409 return sal_False;
411 // -------------------------------------------------------------------------
412 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsTypeConversion( ) throw(SQLException, RuntimeException)
414 return sal_False;
416 // -------------------------------------------------------------------------
417 sal_Bool SAL_CALL MacabDatabaseMetaData::nullPlusNonNullIsNull( ) throw(SQLException, RuntimeException)
419 return sal_False;
421 // -------------------------------------------------------------------------
422 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsColumnAliasing( ) throw(SQLException, RuntimeException)
424 return sal_False;
426 // -------------------------------------------------------------------------
427 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsTableCorrelationNames( ) throw(SQLException, RuntimeException)
429 return sal_False;
431 // -------------------------------------------------------------------------
432 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsConvert( sal_Int32, sal_Int32 ) throw(SQLException, RuntimeException)
434 return sal_False;
436 // -------------------------------------------------------------------------
437 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsExpressionsInOrderBy( ) throw(SQLException, RuntimeException)
439 return sal_False;
441 // -------------------------------------------------------------------------
442 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsGroupBy( ) throw(SQLException, RuntimeException)
444 return sal_False;
446 // -------------------------------------------------------------------------
447 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsGroupByBeyondSelect( ) throw(SQLException, RuntimeException)
449 return sal_False;
451 // -------------------------------------------------------------------------
452 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsGroupByUnrelated( ) throw(SQLException, RuntimeException)
454 return sal_False;
456 // -------------------------------------------------------------------------
457 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsMultipleTransactions( ) throw(SQLException, RuntimeException)
459 return sal_False;
461 // -------------------------------------------------------------------------
462 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsMultipleResultSets( ) throw(SQLException, RuntimeException)
464 return sal_False;
466 // -------------------------------------------------------------------------
467 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsLikeEscapeClause( ) throw(SQLException, RuntimeException)
469 return sal_False;
471 // -------------------------------------------------------------------------
472 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsOrderByUnrelated( ) throw(SQLException, RuntimeException)
474 return sal_False;
476 // -------------------------------------------------------------------------
477 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsUnion( ) throw(SQLException, RuntimeException)
479 return sal_False;
481 // -------------------------------------------------------------------------
482 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsUnionAll( ) throw(SQLException, RuntimeException)
484 return sal_False;
486 // -------------------------------------------------------------------------
487 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsMixedCaseIdentifiers( ) throw(SQLException, RuntimeException)
489 return sal_False;
491 // -------------------------------------------------------------------------
492 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsMixedCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException)
494 return sal_False;
496 // -------------------------------------------------------------------------
497 sal_Bool SAL_CALL MacabDatabaseMetaData::nullsAreSortedAtEnd( ) throw(SQLException, RuntimeException)
499 return sal_False;
501 // -------------------------------------------------------------------------
502 sal_Bool SAL_CALL MacabDatabaseMetaData::nullsAreSortedAtStart( ) throw(SQLException, RuntimeException)
504 return sal_False;
506 // -------------------------------------------------------------------------
507 sal_Bool SAL_CALL MacabDatabaseMetaData::nullsAreSortedHigh( ) throw(SQLException, RuntimeException)
509 return sal_False;
511 // -------------------------------------------------------------------------
512 sal_Bool SAL_CALL MacabDatabaseMetaData::nullsAreSortedLow( ) throw(SQLException, RuntimeException)
514 return sal_False;
516 // -------------------------------------------------------------------------
517 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSchemasInProcedureCalls( ) throw(SQLException, RuntimeException)
519 return sal_False;
521 // -------------------------------------------------------------------------
522 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSchemasInPrivilegeDefinitions( ) throw(SQLException, RuntimeException)
524 return sal_False;
526 // -------------------------------------------------------------------------
527 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsCatalogsInProcedureCalls( ) throw(SQLException, RuntimeException)
529 return sal_False;
531 // -------------------------------------------------------------------------
532 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsCatalogsInPrivilegeDefinitions( ) throw(SQLException, RuntimeException)
534 return sal_False;
536 // -------------------------------------------------------------------------
537 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsCorrelatedSubqueries( ) throw(SQLException, RuntimeException)
539 return sal_False;
541 // -------------------------------------------------------------------------
542 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSubqueriesInComparisons( ) throw(SQLException, RuntimeException)
544 return sal_False;
546 // -------------------------------------------------------------------------
547 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSubqueriesInExists( ) throw(SQLException, RuntimeException)
549 return sal_False;
551 // -------------------------------------------------------------------------
552 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSubqueriesInIns( ) throw(SQLException, RuntimeException)
554 return sal_False;
556 // -------------------------------------------------------------------------
557 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsSubqueriesInQuantifieds( ) throw(SQLException, RuntimeException)
559 return sal_False;
561 // -------------------------------------------------------------------------
562 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsANSI92IntermediateSQL( ) throw(SQLException, RuntimeException)
564 return sal_False;
566 // -------------------------------------------------------------------------
567 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getURL( ) throw(SQLException, RuntimeException)
569 // if someday we support more than the default address book,
570 // this method should return the URL which was used to create it
571 ::rtl::OUString aValue = ::rtl::OUString::createFromAscii("sdbc:address:macab:");
572 return aValue;
574 // -------------------------------------------------------------------------
575 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getUserName( ) throw(SQLException, RuntimeException)
577 ::rtl::OUString aValue;
578 return aValue;
580 // -------------------------------------------------------------------------
581 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getDriverName( ) throw(SQLException, RuntimeException)
583 ::rtl::OUString aValue = ::rtl::OUString::createFromAscii("macab");
584 return aValue;
586 // -------------------------------------------------------------------------
587 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getDriverVersion() throw(SQLException, RuntimeException)
589 ::rtl::OUString aValue = ::rtl::OUString::createFromAscii(MACAB_DRIVER_VERSION);
590 return aValue;
592 // -------------------------------------------------------------------------
593 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getDatabaseProductVersion( ) throw(SQLException, RuntimeException)
595 ::rtl::OUString aValue;
596 return aValue;
598 // -------------------------------------------------------------------------
599 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getDatabaseProductName( ) throw(SQLException, RuntimeException)
601 ::rtl::OUString aValue;
602 return aValue;
604 // -------------------------------------------------------------------------
605 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getProcedureTerm( ) throw(SQLException, RuntimeException)
607 ::rtl::OUString aValue;
608 return aValue;
610 // -------------------------------------------------------------------------
611 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getSchemaTerm( ) throw(SQLException, RuntimeException)
613 ::rtl::OUString aValue;
614 return aValue;
616 // -------------------------------------------------------------------------
617 sal_Int32 SAL_CALL MacabDatabaseMetaData::getDriverMajorVersion( ) throw(RuntimeException)
619 return MACAB_DRIVER_VERSION_MAJOR;
621 // -------------------------------------------------------------------------
622 sal_Int32 SAL_CALL MacabDatabaseMetaData::getDefaultTransactionIsolation( ) throw(SQLException, RuntimeException)
624 return TransactionIsolation::NONE;
626 // -------------------------------------------------------------------------
627 sal_Int32 SAL_CALL MacabDatabaseMetaData::getDriverMinorVersion( ) throw(RuntimeException)
629 return MACAB_DRIVER_VERSION_MINOR;
631 // -------------------------------------------------------------------------
632 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getSQLKeywords( ) throw(SQLException, RuntimeException)
634 ::rtl::OUString aValue;
635 return aValue;
637 // -------------------------------------------------------------------------
638 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getSearchStringEscape( ) throw(SQLException, RuntimeException)
640 ::rtl::OUString aValue;
641 return aValue;
643 // -------------------------------------------------------------------------
644 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getStringFunctions( ) throw(SQLException, RuntimeException)
646 return ::rtl::OUString();
648 // -------------------------------------------------------------------------
649 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getTimeDateFunctions( ) throw(SQLException, RuntimeException)
651 return ::rtl::OUString();
653 // -------------------------------------------------------------------------
654 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getSystemFunctions( ) throw(SQLException, RuntimeException)
656 return ::rtl::OUString();
658 // -------------------------------------------------------------------------
659 ::rtl::OUString SAL_CALL MacabDatabaseMetaData::getNumericFunctions( ) throw(SQLException, RuntimeException)
661 return ::rtl::OUString();
663 // -------------------------------------------------------------------------
664 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsExtendedSQLGrammar( ) throw(SQLException, RuntimeException)
666 return sal_False;
668 // -------------------------------------------------------------------------
669 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsCoreSQLGrammar( ) throw(SQLException, RuntimeException)
671 return sal_False;
673 // -------------------------------------------------------------------------
674 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsMinimumSQLGrammar( ) throw(SQLException, RuntimeException)
676 return sal_True;
678 // -------------------------------------------------------------------------
679 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsFullOuterJoins( ) throw(SQLException, RuntimeException)
681 return sal_False;
683 // -------------------------------------------------------------------------
684 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsLimitedOuterJoins( ) throw(SQLException, RuntimeException)
686 return sal_False;
688 // -------------------------------------------------------------------------
689 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxColumnsInGroupBy( ) throw(SQLException, RuntimeException)
691 sal_Int32 nValue = 0; // 0 means no limit
692 return nValue;
694 // -------------------------------------------------------------------------
695 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxColumnsInOrderBy( ) throw(SQLException, RuntimeException)
697 sal_Int32 nValue = 0; // 0 means no limit
698 return nValue;
700 // -------------------------------------------------------------------------
701 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxColumnsInSelect( ) throw(SQLException, RuntimeException)
703 sal_Int32 nValue = 0; // 0 means no limit
704 return nValue;
706 // -------------------------------------------------------------------------
707 sal_Int32 SAL_CALL MacabDatabaseMetaData::getMaxUserNameLength( ) throw(SQLException, RuntimeException)
709 sal_Int32 nValue = 0; // 0 means no limit
710 return nValue;
712 // -------------------------------------------------------------------------
713 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsResultSetType( sal_Int32 setType ) throw(SQLException, RuntimeException)
715 switch (setType)
717 case ResultSetType::FORWARD_ONLY:
718 case ResultSetType::SCROLL_INSENSITIVE:
719 return sal_True;
721 return sal_False;
723 // -------------------------------------------------------------------------
724 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsResultSetConcurrency( sal_Int32 setType, sal_Int32 ) throw(SQLException, RuntimeException)
726 switch (setType)
728 case ResultSetType::FORWARD_ONLY:
729 case ResultSetType::SCROLL_INSENSITIVE:
730 return sal_True;
732 return sal_False;
734 // -------------------------------------------------------------------------
735 sal_Bool SAL_CALL MacabDatabaseMetaData::ownUpdatesAreVisible( sal_Int32 ) throw(SQLException, RuntimeException)
737 return sal_False;
739 // -------------------------------------------------------------------------
740 sal_Bool SAL_CALL MacabDatabaseMetaData::ownDeletesAreVisible( sal_Int32 ) throw(SQLException, RuntimeException)
742 return sal_False;
744 // -------------------------------------------------------------------------
745 sal_Bool SAL_CALL MacabDatabaseMetaData::ownInsertsAreVisible( sal_Int32 ) throw(SQLException, RuntimeException)
747 return sal_False;
749 // -------------------------------------------------------------------------
750 sal_Bool SAL_CALL MacabDatabaseMetaData::othersUpdatesAreVisible( sal_Int32 ) throw(SQLException, RuntimeException)
752 return sal_False;
754 // -------------------------------------------------------------------------
755 sal_Bool SAL_CALL MacabDatabaseMetaData::othersDeletesAreVisible( sal_Int32 ) throw(SQLException, RuntimeException)
757 return sal_False;
759 // -------------------------------------------------------------------------
760 sal_Bool SAL_CALL MacabDatabaseMetaData::othersInsertsAreVisible( sal_Int32 ) throw(SQLException, RuntimeException)
762 return sal_False;
764 // -------------------------------------------------------------------------
765 sal_Bool SAL_CALL MacabDatabaseMetaData::updatesAreDetected( sal_Int32 ) throw(SQLException, RuntimeException)
767 return sal_False;
769 // -------------------------------------------------------------------------
770 sal_Bool SAL_CALL MacabDatabaseMetaData::deletesAreDetected( sal_Int32 ) throw(SQLException, RuntimeException)
772 return sal_False;
774 // -------------------------------------------------------------------------
775 sal_Bool SAL_CALL MacabDatabaseMetaData::insertsAreDetected( sal_Int32 ) throw(SQLException, RuntimeException)
777 return sal_False;
779 // -------------------------------------------------------------------------
780 sal_Bool SAL_CALL MacabDatabaseMetaData::supportsBatchUpdates( ) throw(SQLException, RuntimeException)
782 return sal_False;
784 // -------------------------------------------------------------------------
785 Reference< XConnection > SAL_CALL MacabDatabaseMetaData::getConnection( ) throw(SQLException, RuntimeException)
787 return (Reference< XConnection >) m_xConnection.get();
789 // -------------------------------------------------------------------------
790 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getTableTypes( ) throw(SQLException, RuntimeException)
792 ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet(ODatabaseMetaDataResultSet::eTableTypes);
793 Reference< XResultSet > xRef = pResult;
795 static ODatabaseMetaDataResultSet::ORows aRows;
796 static const ::rtl::OUString aTable(::rtl::OUString::createFromAscii("TABLE"));
798 if (aRows.empty())
800 ODatabaseMetaDataResultSet::ORow aRow(2);
801 aRow[0] = ODatabaseMetaDataResultSet::getEmptyValue();
802 aRow[1] = new ORowSetValueDecorator(aTable);
803 aRows.push_back(aRow);
805 pResult->setRows(aRows);
806 return xRef;
808 // -------------------------------------------------------------------------
809 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getTypeInfo( ) throw(SQLException, RuntimeException)
811 ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet(ODatabaseMetaDataResultSet::eTypeInfo);
812 Reference< XResultSet > xRef = pResult;
814 static ODatabaseMetaDataResultSet::ORows aRows;
815 if (aRows.empty())
817 ODatabaseMetaDataResultSet::ORow aRow(19);
819 // We support four types: char, timestamp, integer, float
820 aRow[0] = ODatabaseMetaDataResultSet::getEmptyValue();
821 aRow[1] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("CHAR"));
822 aRow[2] = new ORowSetValueDecorator(DataType::CHAR);
823 aRow[3] = new ORowSetValueDecorator((sal_Int32) 254);
824 aRow[4] = ODatabaseMetaDataResultSet::getQuoteValue();
825 aRow[5] = ODatabaseMetaDataResultSet::getQuoteValue();
826 aRow[6] = ODatabaseMetaDataResultSet::getEmptyValue();
827 aRow[7] = new ORowSetValueDecorator((sal_Int32) ColumnValue::NULLABLE);
828 aRow[8] = ODatabaseMetaDataResultSet::get1Value();
829 aRow[9] = new ORowSetValueDecorator((sal_Int32) ColumnSearch::CHAR);
830 aRow[10] = ODatabaseMetaDataResultSet::get1Value();
831 aRow[11] = ODatabaseMetaDataResultSet::get0Value();
832 aRow[12] = ODatabaseMetaDataResultSet::get0Value();
833 aRow[13] = ODatabaseMetaDataResultSet::getEmptyValue();
834 aRow[14] = ODatabaseMetaDataResultSet::get0Value();
835 aRow[15] = ODatabaseMetaDataResultSet::get0Value();
836 aRow[16] = ODatabaseMetaDataResultSet::getEmptyValue();
837 aRow[17] = ODatabaseMetaDataResultSet::getEmptyValue();
838 aRow[18] = new ORowSetValueDecorator((sal_Int32) 10);
840 aRows.push_back(aRow);
842 aRow[1] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("TIMESTAMP"));
843 aRow[2] = new ORowSetValueDecorator(DataType::TIMESTAMP);
844 aRow[3] = new ORowSetValueDecorator((sal_Int32)19);
845 aRow[4] = ODatabaseMetaDataResultSet::getQuoteValue();
846 aRow[5] = ODatabaseMetaDataResultSet::getQuoteValue();
847 aRows.push_back(aRow);
849 aRow[1] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("INTEGER"));
850 aRow[2] = new ORowSetValueDecorator(DataType::INTEGER);
851 aRow[3] = new ORowSetValueDecorator((sal_Int32)20);
852 aRow[15] = new ORowSetValueDecorator((sal_Int32)20);
853 aRows.push_back(aRow);
855 aRow[1] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("FLOAT"));
856 aRow[2] = new ORowSetValueDecorator(DataType::FLOAT);
857 aRow[3] = new ORowSetValueDecorator((sal_Int32)20);
858 aRow[15] = new ORowSetValueDecorator((sal_Int32)15);
859 aRows.push_back(aRow);
861 pResult->setRows(aRows);
862 return xRef;
864 // -------------------------------------------------------------------------
865 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getCatalogs( ) throw(SQLException, RuntimeException)
867 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eCatalogs );
869 // -----------------------------------------------------------------------------
870 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getSchemas( ) throw(SQLException, RuntimeException)
872 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eSchemas );
874 // -------------------------------------------------------------------------
875 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getColumnPrivileges(
876 const Any&, const ::rtl::OUString&, const ::rtl::OUString&,
877 const ::rtl::OUString& ) throw(SQLException, RuntimeException)
879 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eColumnPrivileges );
881 // -------------------------------------------------------------------------
882 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getColumns(
883 const Any&,
884 const ::rtl::OUString&,
885 const ::rtl::OUString& tableNamePattern,
886 const ::rtl::OUString& columnNamePattern) throw(SQLException, RuntimeException)
888 ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet(::connectivity::ODatabaseMetaDataResultSet::eColumns);
889 Reference< XResultSet > xRef = pResult;
890 MacabRecords *aRecords;
891 ::rtl::OUString sTableName;
893 aRecords = m_xConnection->getAddressBook()->getMacabRecordsMatch(tableNamePattern);
895 ODatabaseMetaDataResultSet::ORows aRows;
896 if(aRecords != NULL)
898 MacabHeader *aHeader = aRecords->getHeader();
899 sTableName = aRecords->getName();
901 ODatabaseMetaDataResultSet::ORow aRow(19);
903 aRow[0] = ODatabaseMetaDataResultSet::getEmptyValue();
904 aRow[1] = ODatabaseMetaDataResultSet::getEmptyValue();
905 aRow[2] = ODatabaseMetaDataResultSet::getEmptyValue();
906 aRow[3] = new ORowSetValueDecorator(sTableName);
907 aRow[8] = ODatabaseMetaDataResultSet::getEmptyValue();
908 aRow[9] = ODatabaseMetaDataResultSet::get0Value();
909 aRow[10] = new ORowSetValueDecorator((sal_Int32) 10);
910 aRow[11] = ODatabaseMetaDataResultSet::get1Value();
911 aRow[12] = ODatabaseMetaDataResultSet::getEmptyValue();
912 aRow[13] = ODatabaseMetaDataResultSet::getEmptyValue();
913 aRow[14] = ODatabaseMetaDataResultSet::getEmptyValue();
914 aRow[15] = ODatabaseMetaDataResultSet::getEmptyValue();
915 aRow[16] = new ORowSetValueDecorator((sal_Int32) 254);
916 aRow[18] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("YES"));
918 sal_Int32 nPosition = 1;
919 ::rtl::OUString sName;
921 MacabHeader::iterator aField;
923 for ( aField = aHeader->begin();
924 aField != aHeader->end();
925 ++aField, ++nPosition)
928 sName = CFStringToOUString((CFStringRef) (*aField)->value);
929 if (match(columnNamePattern, sName, '\0'))
931 aRow[4] = new ORowSetValueDecorator(sName);
932 aRow[17] = new ORowSetValueDecorator(nPosition);
933 switch((*aField)->type)
935 case kABStringProperty:
936 aRow[5] = new ORowSetValueDecorator(DataType::CHAR);
937 aRow[6] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("CHAR"));
938 aRow[7] = new ORowSetValueDecorator((sal_Int32) 256);
939 aRows.push_back(aRow);
940 break;
941 case kABDateProperty:
942 aRow[5] = new ORowSetValueDecorator(DataType::TIMESTAMP);
943 aRow[6] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("TIMESTAMP"));
944 aRows.push_back(aRow);
945 break;
946 case kABIntegerProperty:
947 aRow[5] = new ORowSetValueDecorator(DataType::INTEGER);
948 aRow[6] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("INTEGER"));
949 aRow[7] = new ORowSetValueDecorator((sal_Int32) 20);
950 aRows.push_back(aRow);
951 break;
952 case kABRealProperty:
953 aRow[5] = new ORowSetValueDecorator(DataType::FLOAT);
954 aRow[6] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("FLOAT"));
955 aRow[7] = new ORowSetValueDecorator((sal_Int32) 15);
956 aRows.push_back(aRow);
957 break;
958 default:
960 // shouldn't happen -- throw an error...?
965 pResult->setRows(aRows);
966 return xRef;
968 // -------------------------------------------------------------------------
969 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getTables(
970 const Any&,
971 const ::rtl::OUString&,
972 const ::rtl::OUString&,
973 const Sequence< ::rtl::OUString >& types) throw(SQLException, RuntimeException)
975 ODatabaseMetaDataResultSet* pResult = new ODatabaseMetaDataResultSet(::connectivity::ODatabaseMetaDataResultSet::eTables);
976 Reference< XResultSet > xRef = pResult;
978 // check whether we have tables in the requested types
979 // for the moment, we answer only the "TABLE" table type
980 // when no types are given at all, we return all the tables
981 static const ::rtl::OUString aTable(::rtl::OUString::createFromAscii("TABLE"));
982 sal_Bool bTableFound = sal_False;
983 const ::rtl::OUString* p = types.getConstArray(),
984 * pEnd = p + types.getLength();
986 if (p == pEnd)
988 bTableFound = sal_True;
990 else while (p < pEnd)
992 if (match(*p, aTable, '\0'))
994 bTableFound = sal_True;
995 break;
997 p++;
999 if (!bTableFound)
1000 return xRef;
1002 static ODatabaseMetaDataResultSet::ORows aRows;
1004 if (aRows.empty())
1006 ODatabaseMetaDataResultSet::ORow aRow(6);
1008 MacabRecords *xRecords = m_xConnection->getAddressBook()->getMacabRecords();
1009 ::std::vector<MacabGroup *> xGroups = m_xConnection->getAddressBook()->getMacabGroups();
1010 sal_Int32 i, nGroups;
1011 nGroups = xGroups.size();
1013 aRow[0] = ODatabaseMetaDataResultSet::getEmptyValue();
1014 aRow[1] = ODatabaseMetaDataResultSet::getEmptyValue();
1015 aRow[2] = ODatabaseMetaDataResultSet::getEmptyValue();
1016 aRow[3] = new ORowSetValueDecorator(xRecords->getName());
1017 aRow[4] = new ORowSetValueDecorator(aTable);
1018 aRow[5] = ODatabaseMetaDataResultSet::getEmptyValue();
1019 aRows.push_back(aRow);
1021 for(i = 0; i < nGroups; i++)
1023 aRow[3] = new ORowSetValueDecorator(xGroups[i]->getName());
1024 aRows.push_back(aRow);
1027 pResult->setRows(aRows);
1028 return xRef;
1030 // -------------------------------------------------------------------------
1031 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getProcedureColumns(
1032 const Any&, const ::rtl::OUString&,
1033 const ::rtl::OUString&, const ::rtl::OUString& ) throw(SQLException, RuntimeException)
1035 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eProcedureColumns );
1037 // -------------------------------------------------------------------------
1038 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getProcedures(
1039 const Any&, const ::rtl::OUString&,
1040 const ::rtl::OUString& ) throw(SQLException, RuntimeException)
1042 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eProcedures );
1044 // -------------------------------------------------------------------------
1045 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getVersionColumns(
1046 const Any&, const ::rtl::OUString&, const ::rtl::OUString& table ) throw(SQLException, RuntimeException)
1048 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eVersionColumns );
1050 ::connectivity::ODatabaseMetaDataResultSet* pResult = new ::connectivity::ODatabaseMetaDataResultSet(::connectivity::ODatabaseMetaDataResultSet::eVersionColumns);
1051 Reference< XResultSet > xRef = pResult;
1053 ODatabaseMetaDataResultSet::ORows aRows;
1055 if (m_xConnection->getAddressBook()->getMacabRecords(table) != NULL)
1057 ODatabaseMetaDataResultSet::ORow aRow( 9 );
1059 ::rtl::OUString sName = CFStringToOUString(kABModificationDateProperty);
1061 aRow[0] = ODatabaseMetaDataResultSet::getEmptyValue();
1062 aRow[1] = ODatabaseMetaDataResultSet::getEmptyValue();
1063 aRow[2] = new ORowSetValueDecorator(sName);
1064 aRow[3] = new ORowSetValueDecorator(DataType::TIMESTAMP);
1065 aRow[4] = new ORowSetValueDecorator(::rtl::OUString::createFromAscii("TIMESTAMP"));
1067 aRow[5] = ODatabaseMetaDataResultSet::getEmptyValue();
1068 aRow[6] = ODatabaseMetaDataResultSet::getEmptyValue();
1069 aRow[7] = ODatabaseMetaDataResultSet::getEmptyValue();
1070 aRow[8] = ODatabaseMetaDataResultSet::getEmptyValue();
1072 aRows.push_back(aRow);
1074 pResult->setRows(aRows);
1075 return xRef;
1077 // -------------------------------------------------------------------------
1078 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getExportedKeys(
1079 const Any&, const ::rtl::OUString&, const ::rtl::OUString& ) throw(SQLException, RuntimeException)
1081 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eExportedKeys );
1083 // -------------------------------------------------------------------------
1084 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getImportedKeys(
1085 const Any&, const ::rtl::OUString&, const ::rtl::OUString& ) throw(SQLException, RuntimeException)
1087 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eImportedKeys );
1089 // -------------------------------------------------------------------------
1090 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getPrimaryKeys(
1091 const Any&, const ::rtl::OUString&, const ::rtl::OUString& ) throw(SQLException, RuntimeException)
1093 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::ePrimaryKeys );
1095 // -------------------------------------------------------------------------
1096 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getIndexInfo(
1097 const Any&, const ::rtl::OUString&, const ::rtl::OUString&,
1098 sal_Bool, sal_Bool ) throw(SQLException, RuntimeException)
1100 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eIndexInfo );
1102 // -------------------------------------------------------------------------
1103 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getBestRowIdentifier(
1104 const Any&, const ::rtl::OUString&, const ::rtl::OUString&, sal_Int32,
1105 sal_Bool ) throw(SQLException, RuntimeException)
1107 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eBestRowIdentifier );
1109 // -------------------------------------------------------------------------
1110 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getTablePrivileges(
1111 const Any&, const ::rtl::OUString&, const ::rtl::OUString& ) throw(SQLException, RuntimeException)
1113 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eTablePrivileges );
1115 // -------------------------------------------------------------------------
1116 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getCrossReference(
1117 const Any&, const ::rtl::OUString&,
1118 const ::rtl::OUString&, const Any&,
1119 const ::rtl::OUString&, const ::rtl::OUString& ) throw(SQLException, RuntimeException)
1121 return new ODatabaseMetaDataResultSet( ODatabaseMetaDataResultSet::eCrossReference );
1123 // -------------------------------------------------------------------------
1124 Reference< XResultSet > SAL_CALL MacabDatabaseMetaData::getUDTs( const Any&, const ::rtl::OUString&, const ::rtl::OUString&, const Sequence< sal_Int32 >& ) throw(SQLException, RuntimeException)
1126 OSL_ENSURE(0,"Not implemented yet!");
1127 throw SQLException();
1129 // -----------------------------------------------------------------------------