LibreOffice Module connectivity (master) 1
ADatabaseMetaData.cxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
22#include <com/sun/star/sdbc/DataType.hpp>
23#include <com/sun/star/sdbc/ResultSetType.hpp>
24#include <com/sun/star/sdbc/ResultSetConcurrency.hpp>
25#include <com/sun/star/sdbc/TransactionIsolation.hpp>
26#include <ado/AConnection.hxx>
27#include <ado/adoimp.hxx>
29#include <comphelper/types.hxx>
31#include <rtl/ref.hxx>
32
33using namespace ::comphelper;
34
35using namespace connectivity;
36using namespace connectivity::ado;
37using namespace com::sun::star::uno;
38using namespace com::sun::star::lang;
39using namespace com::sun::star::beans;
40using namespace com::sun::star::sdbc;
41
42
43ODatabaseMetaData::ODatabaseMetaData(OConnection* _pCon)
44 : ::connectivity::ODatabaseMetaDataBase(_pCon,_pCon->getConnectionInfo())
45 ,m_rADOConnection(_pCon->getConnection())
46 ,m_pConnection(_pCon)
47{
48}
49
50sal_Int32 ODatabaseMetaData::getInt32Property(const OUString& _aProperty)
51{
53 // ADOS::ThrowException(m_rADOConnection,*this);
54 OSL_ENSURE(aProps.IsValid(),"There are no properties at the connection");
55 ADO_PROP(_aProperty);
56 sal_Int32 nValue(0);
57 if(!aVar.isNull() && !aVar.isEmpty())
58 nValue = aVar.getInt32();
59 return nValue;
60}
61
62
63bool ODatabaseMetaData::getBoolProperty(const OUString& _aProperty)
64{
67 OSL_ENSURE(aProps.IsValid(),"There are no properties at the connection");
68 ADO_PROP(_aProperty);
69 return !aVar.isNull() && !aVar.isEmpty() && aVar.getBool();
70}
71
72OUString ODatabaseMetaData::getStringProperty(const OUString& _aProperty)
73{
76 OSL_ENSURE(aProps.IsValid(),"There are no properties at the connection");
77
78 ADO_PROP(_aProperty);
79 OUString aValue;
80 if(!aVar.isNull() && !aVar.isEmpty() && aVar.getType() == VT_BSTR)
81 aValue = aVar.getString();
82
83 return aValue;
84}
85
87{
88 ADORecordset *pRecordset = m_rADOConnection.getTypeInfo();
89
91 pResult->setTypeInfoMap(ADOS::isJetEngine(m_pConnection->getEngineType()));
92 return pResult;
93}
94
96{
97 OLEVariant vtEmpty;
98 vtEmpty.setNoArg();
99
100 ADORecordset *pRecordset = nullptr;
101 m_rADOConnection.OpenSchema(adSchemaCatalogs,vtEmpty,vtEmpty,&pRecordset);
103
105 pResult->setCatalogsMap();
106
107 return pResult;
108}
109
111{
112 return getLiteral(DBLITERAL_CATALOG_SEPARATOR);
113}
114
116{
117 OLEVariant vtEmpty;
118 vtEmpty.setNoArg();
119
120 ADORecordset *pRecordset = nullptr;
121 m_rADOConnection.OpenSchema(adSchemaSchemata,vtEmpty,vtEmpty,&pRecordset);
123
125 pResult->setSchemasMap();
126 return pResult;
127}
128
130 const Any& catalog, const OUString& schema, const OUString& table,
131 const OUString& columnNamePattern )
132{
133 ADORecordset *pRecordset = m_rADOConnection.getColumnPrivileges(catalog,schema,table,columnNamePattern);
135
137 pResult->setColumnPrivilegesMap();
138 return pResult;
139}
140
142 const Any& catalog, const OUString& schemaPattern, const OUString& tableNamePattern,
143 const OUString& columnNamePattern )
144{
145 ADORecordset *pRecordset = m_rADOConnection.getColumns(catalog,schemaPattern,tableNamePattern,columnNamePattern);
147
149 pResult->setColumnsMap();
150
151 return pResult;
152}
153
155 const Any& catalog, const OUString& schemaPattern,
156 const OUString& tableNamePattern, const Sequence< OUString >& types )
157{
158 ADORecordset *pRecordset = m_rADOConnection.getTables(catalog,schemaPattern,tableNamePattern,types);
160
162 pResult->setTablesMap();
163
164 return pResult;
165}
166
168 const Any& catalog, const OUString& schemaPattern,
169 const OUString& procedureNamePattern, const OUString& columnNamePattern )
170{
171 ADORecordset *pRecordset = m_rADOConnection.getProcedureColumns(catalog,schemaPattern,procedureNamePattern,columnNamePattern);
173
175 pResult->setProcedureColumnsMap();
176
177 return pResult;
178}
179
181 const Any& catalog, const OUString& schemaPattern,
182 const OUString& procedureNamePattern )
183{
184 // Create elements used in the array
185 ADORecordset *pRecordset = m_rADOConnection.getProcedures(catalog,schemaPattern,procedureNamePattern);
187
189 pResult->setProceduresMap();
190
191 return pResult;
192}
193
195{
196 return getMaxSize(DBLITERAL_BINARY_LITERAL);
197}
198
200{
201 return getInt32Property("Maximum Row Size");
202}
203
205{
206 return getMaxSize(DBLITERAL_CATALOG_NAME);
207}
208
210{
211 return getMaxSize(DBLITERAL_CHAR_LITERAL);
212}
213
215{
216 return getMaxSize(DBLITERAL_COLUMN_NAME);
217}
218
220{
221 return 0;
222}
223
225{
226 return getMaxSize(DBLITERAL_CURSOR_NAME);
227}
228
230{
231 return getInt32Property("Active Sessions");
232}
233
235{
236 return getInt32Property("Max Columns in Table");
237}
238
240{
241 return getMaxSize(DBLITERAL_TEXT_COMMAND);
242}
243
245{
246 return getMaxSize(DBLITERAL_TABLE_NAME);
247}
248
250{
251 return getInt32Property("Maximum Tables in SELECT");
252}
253
255 const Any& catalog, const OUString& schema, const OUString& table )
256{
257 ADORecordset *pRecordset = m_rADOConnection.getExportedKeys(catalog,schema,table);
259
261 pResult->setCrossReferenceMap();
262
263 return pResult;
264}
265
267 const Any& catalog, const OUString& schema, const OUString& table )
268{
269 ADORecordset *pRecordset = m_rADOConnection.getImportedKeys(catalog,schema,table);
271
273 pResult->setCrossReferenceMap();
274
275 return pResult;
276}
277
279 const Any& catalog, const OUString& schema, const OUString& table )
280{
281 ADORecordset *pRecordset = m_rADOConnection.getPrimaryKeys(catalog,schema,table);
283
285 pResult->setPrimaryKeysMap();
286
287 return pResult;
288}
289
291 const Any& catalog, const OUString& schema, const OUString& table,
292 sal_Bool unique, sal_Bool approximate )
293{
294 ADORecordset *pRecordset = m_rADOConnection.getIndexInfo(catalog,schema,table,unique,approximate);
296
298 pResult->setIndexInfoMap();
299
300 return pResult;
301}
302
304 const Any& catalog, const OUString& schemaPattern, const OUString& tableNamePattern )
305{
308 { // the jet provider doesn't support this method
309 // Create elements used in the array
310
311 ADORecordset *pRecordset = m_rADOConnection.getTablePrivileges(catalog,schemaPattern,tableNamePattern);
313
315 pResult->setTablePrivilegesMap();
316 xRef = pResult;
317 }
318 else
319 {
321 xRef = pResult;
324 aRows.reserve(8);
325
328 aRow[2] = new ::connectivity::ORowSetValueDecorator(tableNamePattern);
331 aRow[5] = new ::connectivity::ORowSetValueDecorator(getUserName());
333 aRow[7] = new ::connectivity::ORowSetValueDecorator(OUString("NO"));
334
335 aRows.push_back(aRow);
337 aRows.push_back(aRow);
339 aRows.push_back(aRow);
341 aRows.push_back(aRow);
343 aRows.push_back(aRow);
345 aRows.push_back(aRow);
347 aRows.push_back(aRow);
349 aRows.push_back(aRow);
350 pResult->setRows(std::move(aRows));
351 }
352
353 return xRef;
354}
355
357 const Any& primaryCatalog, const OUString& primarySchema,
358 const OUString& primaryTable, const Any& foreignCatalog,
359 const OUString& foreignSchema, const OUString& foreignTable )
360{
361 ADORecordset *pRecordset = m_rADOConnection.getCrossReference(primaryCatalog,primarySchema,primaryTable,foreignCatalog,foreignSchema,foreignTable);
363
365 pResult->setCrossReferenceMap();
366
367 return pResult;
368}
369
371{
372 return getBoolProperty("Maximum Row Size Includes BLOB");
373}
374
376{
377 return (getInt32Property("Identifier Case Sensitivity") & DBPROPVAL_IC_LOWER) == DBPROPVAL_IC_LOWER ;
378}
379
381{
382 return (getInt32Property("Identifier Case Sensitivity") & DBPROPVAL_IC_LOWER) == DBPROPVAL_IC_LOWER ;
383}
384
386{
387 return (getInt32Property("Identifier Case Sensitivity") & DBPROPVAL_IC_MIXED) == DBPROPVAL_IC_MIXED ;
388}
389
391{
392 return (getInt32Property("Identifier Case Sensitivity") & DBPROPVAL_IC_MIXED) == DBPROPVAL_IC_MIXED ;
393}
394
396{
397 return (getInt32Property("Identifier Case Sensitivity") & DBPROPVAL_IC_UPPER) == DBPROPVAL_IC_UPPER ;
398}
399
401{
402 return (getInt32Property("Identifier Case Sensitivity") & DBPROPVAL_IC_UPPER) == DBPROPVAL_IC_UPPER ;
403}
404
406{
407 return true;
408}
409
411{
412 return true;
413}
414
416{
417 return getInt32Property("Maximum Index Size");
418}
419
421{
422 return getInt32Property("NULL Concatenation Behavior") == DBPROPVAL_CB_NON_NULL;
423}
424
426{
427 return getStringProperty("Catalog Term");
428}
429
431{
432 return getLiteral(DBLITERAL_QUOTE_PREFIX);
433
434}
435
437{
438 return OUString();
439}
440
442{
443 return isCapable(DBLITERAL_CORRELATION_NAME);
444}
445
447{
448 return getInt32Property("Catalog Location") == DBPROPVAL_CL_START;
449}
450
452{
453 return getInt32Property("Transaction DDL") == DBPROPVAL_TC_DDL_IGNORE;
454}
455
457{
458 return getInt32Property("Transaction DDL") == DBPROPVAL_TC_DDL_COMMIT;
459}
460
462{
463 return getInt32Property("Transaction DDL") == DBPROPVAL_TC_DML;
464}
465
467{
468 return getInt32Property("Transaction DDL") == DBPROPVAL_TC_ALL;
469}
470
472{
473 return true;
474}
475
477{
478 return true;
479}
480
482{
483 return getInt32Property("Prepare Abort Behavior") == DBPROPVAL_CB_PRESERVE;
484}
485
487{
488 return getInt32Property("Prepare Commit Behavior") == DBPROPVAL_CB_PRESERVE;
489}
490
492{
493 return (getInt32Property("Isolation Retention") & DBPROPVAL_TR_COMMIT) == DBPROPVAL_TR_COMMIT;
494}
495
497{
498 return (getInt32Property("Isolation Retention") & DBPROPVAL_TR_ABORT) == DBPROPVAL_TR_ABORT;
499}
500
502{
503 bool bValue(false);
504
505 sal_Int32 nTxn = getInt32Property("Isolation Levels");
506 if(level == TransactionIsolation::NONE)
507 bValue = true;
508 else if(level == TransactionIsolation::READ_UNCOMMITTED)
509 bValue = (nTxn & DBPROPVAL_TI_READUNCOMMITTED) == DBPROPVAL_TI_READUNCOMMITTED;
510 else if(level == TransactionIsolation::READ_COMMITTED)
511 bValue = (nTxn & DBPROPVAL_TI_READCOMMITTED) == DBPROPVAL_TI_READCOMMITTED;
512 else if(level == TransactionIsolation::REPEATABLE_READ)
513 bValue = (nTxn & DBPROPVAL_TI_REPEATABLEREAD) == DBPROPVAL_TI_REPEATABLEREAD;
514 else if(level == TransactionIsolation::SERIALIZABLE)
515 bValue = (nTxn & DBPROPVAL_TI_SERIALIZABLE) == DBPROPVAL_TI_SERIALIZABLE;
516
517 return bValue;
518}
519
521{
522 return (getInt32Property("Schema Usage") & DBPROPVAL_SU_DML_STATEMENTS) == DBPROPVAL_SU_DML_STATEMENTS;
523}
524
526{
527 sal_Int32 nProp = getInt32Property("SQL Support");
528 return (nProp == 512) || ((nProp & DBPROPVAL_SQL_ANSI92_FULL) == DBPROPVAL_SQL_ANSI92_FULL);
529}
530
532{
533 sal_Int32 nProp = getInt32Property("SQL Support");
534 return (nProp == 512) || ((nProp & DBPROPVAL_SQL_ANSI92_ENTRY) == DBPROPVAL_SQL_ANSI92_ENTRY);
535}
536
538{
539 sal_Int32 nProp = getInt32Property("SQL Support");
540 return (nProp == 512) || ((nProp & DBPROPVAL_SQL_ANSI89_IEF) == DBPROPVAL_SQL_ANSI89_IEF);
541}
542
544{
545 return (getInt32Property("Schema Usage") & DBPROPVAL_SU_INDEX_DEFINITION) == DBPROPVAL_SU_INDEX_DEFINITION;
546}
547
549{
550 return (getInt32Property("Schema Usage") & DBPROPVAL_SU_TABLE_DEFINITION) == DBPROPVAL_SU_TABLE_DEFINITION;
551}
552
554{
555 return false;
556}
557
559{
560 return false;
561}
562
564{
565 return false;
566}
567
569{
571 return true;
572 return getBoolProperty("Outer Join Capabilities");
573}
574
576{
577 return new ::connectivity::ODatabaseMetaDataResultSet(::connectivity::ODatabaseMetaDataResultSet::eTableTypes);
578}
579
581{
582 return 0;
583}
584
586{
587 return getMaxSize(DBLITERAL_PROCEDURE_NAME);
588}
589
591{
592 return getMaxSize(DBLITERAL_SCHEMA_NAME);
593}
594
596{
597 return getInt32Property("Transaction DDL") == DBPROPVAL_TC_NONE;
598}
599
601{
602 return true;
603}
604
606{
607 return true;
608}
609
611{
612 return true;
613}
614
616{
617 return true;
618}
619
621{
622 return getBoolProperty("Read-Only Data Source");
623}
624
626{
627 return false;
628}
629
631{
632 return false;
633}
634
636{
637 return true;
638}
639
641{
642 return getInt32Property("NULL Concatenation Behavior") == DBPROPVAL_CB_NULL;
643}
644
646{
647 return isCapable(DBLITERAL_COLUMN_ALIAS);
648}
649
651{
652 return isCapable(DBLITERAL_CORRELATION_NAME);
653}
654
655sal_Bool SAL_CALL ODatabaseMetaData::supportsConvert( sal_Int32 /*fromType*/, sal_Int32 /*toType*/ )
656{
657 return getBoolProperty("Rowset Conversions on Command");
658}
659
661{
662 return getBoolProperty("ORDER BY Columns in Select List");
663}
664
666{
667 return getInt32Property("GROUP BY Support") != DBPROPVAL_GB_NOT_SUPPORTED;
668}
669
671{
672 return getInt32Property("GROUP BY Support") != DBPROPVAL_GB_CONTAINS_SELECT;
673}
674
676{
677 return getInt32Property("GROUP BY Support") == DBPROPVAL_GB_NO_RELATION;
678}
679
681{
682 return true;
683}
684
686{
687 return false;
688}
689
691{
692 return isCapable(DBLITERAL_ESCAPE_PERCENT);
693}
694
696{
697 return getBoolProperty("ORDER BY Columns in Select List");
698}
699
701{
702 return true;
703}
704
706{
707 return true;
708}
709
711{
712 return (getInt32Property("Identifier Case Sensitivity") & DBPROPVAL_IC_MIXED) == DBPROPVAL_IC_MIXED;
713}
714
716{
717 return (getInt32Property("Identifier Case Sensitivity") & DBPROPVAL_IC_MIXED) == DBPROPVAL_IC_MIXED;
718}
719
721{
722 return (getInt32Property("NULL Collation Order") & DBPROPVAL_NC_END) == DBPROPVAL_NC_END;
723}
724
726{
727 return (getInt32Property("NULL Collation Order") & DBPROPVAL_NC_START) == DBPROPVAL_NC_START;
728}
729
731{
732 return (getInt32Property("NULL Collation Order") & DBPROPVAL_NC_HIGH) == DBPROPVAL_NC_HIGH;
733}
734
736{
737 return (getInt32Property("NULL Collation Order") & DBPROPVAL_NC_LOW) == DBPROPVAL_NC_LOW;
738}
739
741{
742 return false;
743}
744
746{
747 return (getInt32Property("Schema Usage") & DBPROPVAL_SU_PRIVILEGE_DEFINITION) == DBPROPVAL_SU_PRIVILEGE_DEFINITION;
748}
749
751{
752 return false;
753}
754
756{
757 return false;
758}
759
761{
762 return (getInt32Property("Subquery Support") & DBPROPVAL_SQ_CORRELATEDSUBQUERIES) == DBPROPVAL_SQ_CORRELATEDSUBQUERIES;
763}
764
766{
767 return (getInt32Property("Subquery Support") & DBPROPVAL_SQ_COMPARISON) == DBPROPVAL_SQ_COMPARISON;
768}
769
771{
772 return (getInt32Property("Subquery Support") & DBPROPVAL_SQ_EXISTS) == DBPROPVAL_SQ_EXISTS;
773}
774
776{
777 return (getInt32Property("Subquery Support") & DBPROPVAL_SQ_IN) == DBPROPVAL_SQ_IN;
778}
779
781{
782 return (getInt32Property("Subquery Support") & DBPROPVAL_SQ_QUANTIFIED) == DBPROPVAL_SQ_QUANTIFIED;
783}
784
786{
787 sal_Int32 nProp = getInt32Property("SQL Support");
788 return (nProp == 512) || ((nProp & DBPROPVAL_SQL_ANSI92_INTERMEDIATE) == DBPROPVAL_SQL_ANSI92_INTERMEDIATE);
789}
790
791OUString SAL_CALL ODatabaseMetaData::getURL( )
792{
793 return "sdbc:ado:"+ m_rADOConnection.GetConnectionString();
794}
795
797{
798 return getStringProperty("User Name");
799}
800
802{
803 return getStringProperty("Provider Friendly Name");
804}
805
807{
808 return getStringProperty("Provider Version");
809}
810
812{
813 return getStringProperty("DBMS Version");
814}
815
817{
818 return getStringProperty("DBMS Name");
819}
820
822{
823 return getStringProperty("Procedure Term");
824}
825
827{
828 return getStringProperty("Schema Term");
829}
830
832{
833 return 1;
834}
835
837{
838 sal_Int32 nRet = TransactionIsolation::NONE;
840 {
841 case adXactReadCommitted:
842 nRet = TransactionIsolation::READ_COMMITTED;
843 break;
844 case adXactRepeatableRead:
845 nRet = TransactionIsolation::REPEATABLE_READ;
846 break;
847 case adXactSerializable:
848 nRet = TransactionIsolation::SERIALIZABLE;
849 break;
850 case adXactReadUncommitted:
851 nRet = TransactionIsolation::READ_UNCOMMITTED;
852 break;
853 default:
854 ;
855 }
856 return nRet;
857}
858
860{
861 return 0;
862}
863
865{
866 WpADORecordset aRecordset;
867 OLEVariant vtEmpty;
868 vtEmpty.setNoArg();
869 m_rADOConnection.OpenSchema(adSchemaDBInfoKeywords,vtEmpty,vtEmpty,&aRecordset);
870 OSL_ENSURE(aRecordset,"getSQLKeywords: no resultset!");
872 if ( aRecordset )
873 {
874 aRecordset.MoveFirst();
875 OLEVariant aValue;
876 OUString aRet;
877 while(!aRecordset.IsAtEOF())
878 {
880 WpADOField aField(aFields.GetItem(0));
881 aField.get_Value(aValue);
882 aRet += aValue.getString() + ",";
883 aRecordset.MoveNext();
884 }
885 aRecordset.Close();
886 if ( !aRet.isEmpty() )
887 return aRet.copy(0,aRet.lastIndexOf(','));
888 }
889 return OUString();
890}
891
893{
894 return getLiteral(DBLITERAL_ESCAPE_PERCENT);
895}
896
898{
899 return OUString();
900}
901
903{
904 return OUString();
905}
906
908{
909 return OUString();
910}
911
913{
914 return OUString();
915}
916
918{
919 sal_Int32 nProp = getInt32Property("SQL Support");
920 return (nProp == 512) || ((nProp & DBPROPVAL_SQL_ODBC_EXTENDED) == DBPROPVAL_SQL_ODBC_EXTENDED);
921}
922
924{
925 sal_Int32 nProp = getInt32Property("SQL Support");
926 return (nProp == 512) || ((nProp & DBPROPVAL_SQL_ODBC_CORE) == DBPROPVAL_SQL_ODBC_CORE);
927}
928
930{
931 sal_Int32 nProp = getInt32Property("SQL Support");
932 return (nProp == 512) || ((nProp & DBPROPVAL_SQL_ODBC_MINIMUM) == DBPROPVAL_SQL_ODBC_MINIMUM);
933}
934
936{
938 return true;
939 return (getInt32Property("Outer Join Capabilities") & 0x00000004L) == 0x00000004L;
940}
941
943{
944 return supportsFullOuterJoins( );
945}
946
948{
949 return getInt32Property("Max Columns in GROUP BY");
950}
951
953{
954 return getInt32Property("Max Columns in ORDER BY");
955}
956
958{
959 return 0;
960}
961
963{
964 return getMaxSize(DBLITERAL_USER_NAME);
965}
966
967sal_Bool SAL_CALL ODatabaseMetaData::supportsResultSetType( sal_Int32 /*setType*/ )
968{
969 return true;
970}
971
972sal_Bool SAL_CALL ODatabaseMetaData::supportsResultSetConcurrency( sal_Int32 /*setType*/, sal_Int32 /*concurrency*/ )
973{
974 return true;
975}
976
978{
979 return ResultSetType::FORWARD_ONLY != setType;
980}
981
983{
984 return ResultSetType::FORWARD_ONLY != setType;
985}
986
988{
989 return ResultSetType::FORWARD_ONLY != setType;
990}
991
993{
994 return ResultSetType::FORWARD_ONLY != setType;
995}
996
998{
999 return ResultSetType::FORWARD_ONLY != setType;
1000}
1001
1003{
1004 return ResultSetType::FORWARD_ONLY != setType;
1005}
1006
1008{
1009 return ResultSetType::FORWARD_ONLY != setType;
1010}
1011
1013{
1014 return ResultSetType::FORWARD_ONLY != setType;
1015}
1016
1018{
1019 return ResultSetType::FORWARD_ONLY != setType;
1020}
1021
1023{
1024 return true;
1025}
1026
1027Reference< XResultSet > SAL_CALL ODatabaseMetaData::getUDTs( const Any& /*catalog*/, const OUString& /*schemaPattern*/, const OUString& /*typeNamePattern*/, const Sequence< sal_Int32 >& /*types*/ )
1028{
1029 ::dbtools::throwFeatureNotImplementedSQLException( "XDatabaseMetaData::getUDTs", *this );
1030 return Reference< XResultSet >();
1031}
1032
1033
1034/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
#define ADO_PROP(ItemName)
Definition: adoimp.hxx:93
static ORowSetValueDecoratorRef const & getEmptyValue()
return an empty ORowSetValueDecorator
static ORowSetValueDecoratorRef const & getAlterValue()
return an ORowSetValueDecorator with string ALTER as value
std::vector< ORowSetValueDecoratorRef > ORow
static ORowSetValueDecoratorRef const & getDeleteValue()
return an ORowSetValueDecorator with string DELETE as value
static ORowSetValueDecoratorRef const & getDropValue()
return an ORowSetValueDecorator with string DROP as value
@ eTableTypes
describes a result set as expected by XDatabaseMetaData::getTableTypes
@ eTablePrivileges
describes a result set as expected by XDatabaseMetaData::getTablePrivileges
static ORowSetValueDecoratorRef const & getInsertValue()
return an ORowSetValueDecorator with string INSERT as value
static ORowSetValueDecoratorRef const & getReadValue()
return an ORowSetValueDecorator with string READ as value
static ORowSetValueDecoratorRef const & getUpdateValue()
return an ORowSetValueDecorator with string UPDATE as value
static ORowSetValueDecoratorRef const & getCreateValue()
return an ORowSetValueDecorator with string CREATE as value
static ORowSetValueDecoratorRef const & getSelectValue()
return an ORowSetValueDecorator with string SELECT as value
static void ThrowException(ADOConnection *_pAdoCon, const css::uno::Reference< css::uno::XInterface > &_xInterface)
Definition: ADriver.cxx:207
static bool isJetEngine(sal_Int32 _nEngineType)
Definition: adoimp.cxx:189
sal_Int32 getEngineType() const
virtual sal_Bool SAL_CALL ownUpdatesAreVisible(sal_Int32 setType) override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getCrossReference(const css::uno::Any &primaryCatalog, const OUString &primarySchema, const OUString &primaryTable, const css::uno::Any &foreignCatalog, const OUString &foreignSchema, const OUString &foreignTable) override
virtual sal_Bool SAL_CALL supportsPositionedDelete() override
virtual sal_Int32 SAL_CALL getMaxColumnsInGroupBy() override
virtual sal_Bool SAL_CALL supportsDataDefinitionAndDataManipulationTransactions() override
OUString getLiteral(sal_uInt32 _nProperty)
virtual sal_Bool SAL_CALL supportsLikeEscapeClause() override
virtual sal_Int32 SAL_CALL getMaxColumnsInIndex() override
virtual sal_Bool SAL_CALL supportsDataManipulationTransactionsOnly() override
virtual sal_Int32 SAL_CALL getMaxIndexLength() override
virtual sal_Bool SAL_CALL dataDefinitionCausesTransactionCommit() override
virtual sal_Bool SAL_CALL storesUpperCaseIdentifiers() override
virtual sal_Int32 SAL_CALL getMaxCatalogNameLength() override
virtual sal_Int32 SAL_CALL getMaxTableNameLength() override
virtual sal_Bool SAL_CALL insertsAreDetected(sal_Int32 setType) override
virtual sal_Bool SAL_CALL storesUpperCaseQuotedIdentifiers() override
virtual sal_Bool SAL_CALL supportsANSI92IntermediateSQL() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getProcedures(const css::uno::Any &catalog, const OUString &schemaPattern, const OUString &procedureNamePattern) override
virtual OUString SAL_CALL getTimeDateFunctions() override
virtual sal_Bool SAL_CALL nullsAreSortedLow() override
virtual sal_Bool SAL_CALL supportsConvert(sal_Int32 fromType, sal_Int32 toType) override
virtual sal_Int32 SAL_CALL getMaxCursorNameLength() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getSchemas() override
virtual OUString SAL_CALL getExtraNameCharacters() override
virtual sal_Int32 SAL_CALL getMaxColumnsInOrderBy() override
virtual sal_Bool SAL_CALL supportsMixedCaseIdentifiers() override
virtual sal_Int32 SAL_CALL getMaxUserNameLength() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getCatalogs() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getTableTypes() override
virtual sal_Int32 SAL_CALL getMaxColumnsInTable() override
virtual sal_Bool SAL_CALL supportsMultipleTransactions() override
virtual sal_Bool SAL_CALL supportsResultSetConcurrency(sal_Int32 setType, sal_Int32 concurrency) override
virtual OUString impl_getCatalogSeparator_throw() override
virtual OUString impl_getIdentifierQuoteString_throw() override
virtual bool impl_isCatalogAtStart_throw() override
virtual sal_Bool SAL_CALL supportsCatalogsInProcedureCalls() override
sal_Int32 getInt32Property(const OUString &_aProperty)
virtual sal_Int32 SAL_CALL getMaxColumnNameLength() override
bool getBoolProperty(const OUString &_aProperty)
virtual sal_Bool SAL_CALL supportsLimitedOuterJoins() override
virtual OUString SAL_CALL getSystemFunctions() override
virtual sal_Int32 SAL_CALL getMaxProcedureNameLength() override
virtual sal_Int32 SAL_CALL getMaxSchemaNameLength() override
virtual sal_Bool SAL_CALL othersDeletesAreVisible(sal_Int32 setType) override
virtual sal_Bool SAL_CALL supportsOpenCursorsAcrossCommit() override
virtual sal_Bool SAL_CALL isReadOnly() override
virtual sal_Bool SAL_CALL supportsGroupByUnrelated() override
virtual sal_Bool SAL_CALL supportsTransactionIsolationLevel(sal_Int32 level) override
virtual sal_Bool SAL_CALL supportsExtendedSQLGrammar() override
virtual sal_Int32 SAL_CALL getMaxCharLiteralLength() override
virtual sal_Bool SAL_CALL supportsPositionedUpdate() override
virtual sal_Bool SAL_CALL supportsIntegrityEnhancementFacility() override
virtual sal_Bool SAL_CALL nullsAreSortedAtStart() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getImportedKeys(const css::uno::Any &catalog, const OUString &schema, const OUString &table) override
virtual sal_Bool SAL_CALL storesLowerCaseIdentifiers() override
virtual bool impl_supportsAlterTableWithAddColumn_throw() override
virtual sal_Bool SAL_CALL supportsCatalogsInIndexDefinitions() override
virtual sal_Bool SAL_CALL supportsExpressionsInOrderBy() override
virtual sal_Bool SAL_CALL supportsFullOuterJoins() override
virtual sal_Bool SAL_CALL nullPlusNonNullIsNull() override
virtual sal_Bool SAL_CALL othersInsertsAreVisible(sal_Int32 setType) override
virtual sal_Bool SAL_CALL supportsCoreSQLGrammar() override
virtual sal_Bool SAL_CALL nullsAreSortedHigh() override
virtual sal_Bool SAL_CALL allProceduresAreCallable() override
virtual sal_Int32 SAL_CALL getMaxColumnsInSelect() override
virtual bool impl_supportsCatalogsInDataManipulation_throw() override
OUString getStringProperty(const OUString &_aProperty)
virtual sal_Bool SAL_CALL storesMixedCaseIdentifiers() override
virtual sal_Bool SAL_CALL supportsOpenCursorsAcrossRollback() override
virtual sal_Int32 SAL_CALL getDriverMinorVersion() override
virtual OUString SAL_CALL getSchemaTerm() override
virtual sal_Bool SAL_CALL nullsAreSortedAtEnd() override
virtual bool impl_supportsMixedCaseQuotedIdentifiers_throw() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getColumns(const css::uno::Any &catalog, const OUString &schemaPattern, const OUString &tableNamePattern, const OUString &columnNamePattern) override
virtual OUString SAL_CALL getDriverVersion() override
virtual sal_Bool SAL_CALL ownDeletesAreVisible(sal_Int32 setType) override
virtual sal_Bool SAL_CALL supportsANSI92EntryLevelSQL() override
virtual sal_Bool SAL_CALL supportsOpenStatementsAcrossCommit() override
virtual sal_Int32 SAL_CALL getMaxStatementLength() override
virtual sal_Bool SAL_CALL supportsANSI92FullSQL() override
virtual sal_Bool SAL_CALL allTablesAreSelectable() override
virtual sal_Bool SAL_CALL supportsSelectForUpdate() override
virtual OUString SAL_CALL getURL() override
virtual sal_Bool SAL_CALL supportsResultSetType(sal_Int32 setType) override
virtual OUString SAL_CALL getCatalogTerm() override
virtual sal_Bool SAL_CALL supportsMultipleResultSets() override
virtual OUString SAL_CALL getUserName() override
virtual sal_Int32 SAL_CALL getDefaultTransactionIsolation() override
virtual OUString SAL_CALL getDatabaseProductVersion() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getExportedKeys(const css::uno::Any &catalog, const OUString &schema, const OUString &table) override
virtual bool impl_supportsSchemasInTableDefinitions_throw() override
virtual sal_Bool SAL_CALL supportsMinimumSQLGrammar() override
virtual sal_Bool SAL_CALL supportsGroupByBeyondSelect() override
virtual OUString SAL_CALL getStringFunctions() override
virtual sal_Int32 SAL_CALL getDriverMajorVersion() override
virtual sal_Bool SAL_CALL doesMaxRowSizeIncludeBlobs() override
virtual sal_Int32 SAL_CALL getMaxBinaryLiteralLength() override
virtual sal_Bool SAL_CALL supportsOpenStatementsAcrossRollback() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getProcedureColumns(const css::uno::Any &catalog, const OUString &schemaPattern, const OUString &procedureNamePattern, const OUString &columnNamePattern) override
virtual sal_Bool SAL_CALL supportsTypeConversion() override
virtual sal_Int32 SAL_CALL getMaxConnections() override
virtual sal_Bool SAL_CALL storesLowerCaseQuotedIdentifiers() override
virtual sal_Bool SAL_CALL supportsCatalogsInPrivilegeDefinitions() override
virtual bool impl_storesMixedCaseQuotedIdentifiers_throw() override
virtual OUString SAL_CALL getSQLKeywords() override
virtual OUString SAL_CALL getDatabaseProductName() override
virtual bool impl_supportsCatalogsInTableDefinitions_throw() override
virtual sal_Bool SAL_CALL supportsSubqueriesInComparisons() override
virtual sal_Bool SAL_CALL supportsSubqueriesInQuantifieds() override
virtual sal_Int32 impl_getMaxTablesInSelect_throw() override
virtual sal_Bool SAL_CALL supportsUnionAll() override
virtual sal_Bool SAL_CALL supportsOrderByUnrelated() override
virtual sal_Bool SAL_CALL othersUpdatesAreVisible(sal_Int32 setType) override
virtual bool impl_supportsAlterTableWithDropColumn_throw() override
virtual sal_Bool SAL_CALL ownInsertsAreVisible(sal_Int32 setType) override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getIndexInfo(const css::uno::Any &catalog, const OUString &schema, const OUString &table, sal_Bool unique, sal_Bool approximate) override
virtual sal_Bool SAL_CALL supportsSubqueriesInIns() override
virtual sal_Bool SAL_CALL dataDefinitionIgnoredInTransactions() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getUDTs(const css::uno::Any &catalog, const OUString &schemaPattern, const OUString &typeNamePattern, const css::uno::Sequence< sal_Int32 > &types) override
virtual sal_Bool SAL_CALL usesLocalFilePerTable() override
virtual sal_Bool SAL_CALL supportsColumnAliasing() override
virtual sal_Bool SAL_CALL deletesAreDetected(sal_Int32 setType) override
virtual sal_Int32 SAL_CALL getMaxRowSize() override
virtual OUString SAL_CALL getProcedureTerm() override
virtual sal_Bool SAL_CALL supportsGroupBy() override
virtual bool impl_supportsSchemasInDataManipulation_throw() override
virtual sal_Bool SAL_CALL supportsSchemasInPrivilegeDefinitions() override
virtual sal_Bool SAL_CALL supportsBatchUpdates() override
virtual sal_Bool SAL_CALL supportsNonNullableColumns() override
virtual sal_Bool SAL_CALL supportsDifferentTableCorrelationNames() override
virtual sal_Bool SAL_CALL supportsCorrelatedSubqueries() override
virtual sal_Bool SAL_CALL supportsUnion() override
virtual OUString SAL_CALL getDriverName() override
virtual sal_Bool SAL_CALL supportsTableCorrelationNames() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getTablePrivileges(const css::uno::Any &catalog, const OUString &schemaPattern, const OUString &tableNamePattern) override
virtual sal_Bool SAL_CALL supportsStoredProcedures() override
virtual sal_Bool SAL_CALL supportsSchemasInProcedureCalls() override
virtual sal_Bool SAL_CALL supportsOuterJoins() override
virtual sal_Bool SAL_CALL updatesAreDetected(sal_Int32 setType) override
virtual sal_Int32 impl_getMaxStatements_throw() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getColumnPrivileges(const css::uno::Any &catalog, const OUString &schema, const OUString &table, const OUString &columnNamePattern) override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getPrimaryKeys(const css::uno::Any &catalog, const OUString &schema, const OUString &table) override
virtual sal_Bool SAL_CALL supportsSubqueriesInExists() override
virtual OUString SAL_CALL getNumericFunctions() override
virtual sal_Bool SAL_CALL usesLocalFiles() override
virtual sal_Bool SAL_CALL supportsSchemasInIndexDefinitions() override
virtual OUString SAL_CALL getSearchStringEscape() override
virtual sal_Bool SAL_CALL supportsTransactions() override
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL getTables(const css::uno::Any &catalog, const OUString &schemaPattern, const OUString &tableNamePattern, const css::uno::Sequence< OUString > &types) override
virtual css::uno::Reference< css::sdbc::XResultSet > impl_getTypeInfo_throw() override
ADORecordset * getExportedKeys(const css::uno::Any &catalog, const OUString &schema, std::u16string_view table)
Definition: Awrapado.cxx:1458
ADORecordset * getIndexInfo(const css::uno::Any &catalog, const OUString &schema, std::u16string_view table, bool unique, bool approximate)
Definition: Awrapado.cxx:1578
ADORecordset * getColumnPrivileges(const css::uno::Any &catalog, const OUString &schemaPattern, std::u16string_view table, std::u16string_view columnNamePattern)
Definition: Awrapado.cxx:1907
bool OpenSchema(SchemaEnum eNum, OLEVariant const &Restrictions, OLEVariant const &SchemaID, ADORecordset **pprset)
Definition: Awrapado.cxx:232
ADORecordset * getColumns(const css::uno::Any &catalog, const OUString &schemaPattern, std::u16string_view tableNamePattern, std::u16string_view columnNamePattern)
Definition: Awrapado.cxx:1863
OUString GetConnectionString() const
Definition: Awrapado.cxx:44
ADORecordset * getCrossReference(const css::uno::Any &primaryCatalog, const OUString &primarySchema, std::u16string_view primaryTable, const css::uno::Any &foreignCatalog, const OUString &foreignSchema, std::u16string_view foreignTable)
Definition: Awrapado.cxx:1663
WpADOProperties get_Properties() const
Definition: Awrapado.cxx:37
ADORecordset * getImportedKeys(const css::uno::Any &catalog, const OUString &schema, std::u16string_view table)
Definition: Awrapado.cxx:1498
ADORecordset * getTables(const css::uno::Any &catalog, const OUString &schemaPattern, std::u16string_view tableNamePattern, const css::uno::Sequence< OUString > &types)
Definition: Awrapado.cxx:1800
ADORecordset * getProcedures(const css::uno::Any &catalog, const OUString &schemaPattern, std::u16string_view procedureNamePattern)
Definition: Awrapado.cxx:1716
ADORecordset * getTypeInfo(DataTypeEnum _eType=adEmpty)
Definition: Awrapado.cxx:1950
ADORecordset * getTablePrivileges(const css::uno::Any &catalog, const OUString &schemaPattern, std::u16string_view tableNamePattern)
Definition: Awrapado.cxx:1621
ADORecordset * getPrimaryKeys(const css::uno::Any &catalog, const OUString &schema, std::u16string_view table)
Definition: Awrapado.cxx:1540
IsolationLevelEnum get_IsolationLevel() const
Definition: Awrapado.cxx:154
ADORecordset * getProcedureColumns(const css::uno::Any &catalog, const OUString &schemaPattern, std::u16string_view procedureNamePattern, std::u16string_view columnNamePattern)
Definition: Awrapado.cxx:1755
void get_Value(OLEVariant &aValVar) const
Definition: Awrapado.cxx:486
WpADOFields GetFields() const
Definition: Awrapado.cxx:765
WrapT GetItem(sal_Int32 index) const
Definition: Aolewrap.hxx:102
sal_Int16 nValue
Reference< XConnection > getConnection(const Reference< XRowSet > &_rxRowSet)
Definition: dbtools.cxx:348
void throwFeatureNotImplementedSQLException(const OUString &_rFeatureName, const Reference< XInterface > &_rxContext, const Any &_rNextException)
#define VT_BSTR
unsigned char sal_Bool