/offapi/com/sun/star/sdbc/XDatabaseMetaData.idl
IDL | 2453 lines | 197 code | 159 blank | 2097 comment | 0 complexity | b8bf9ee063eae02d0787a8aef2d7855b MD5 | raw file
Possible License(s): GPL-3.0, LGPL-3.0, MPL-2.0-no-copyleft-exception, LGPL-2.1, BSD-3-Clause-No-Nuclear-License-2014
Large files files are truncated, but you can click here to view the full 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#ifndef __com_sun_star_sdbc_XDatabaseMetaData_idl__
20#define __com_sun_star_sdbc_XDatabaseMetaData_idl__
21
22#include <com/sun/star/uno/XInterface.idl>
23
24#include <com/sun/star/sdbc/SQLException.idl>
25
26
27 module com { module sun { module star { module sdbc {
28
29 published interface XResultSet;
30 published interface XConnection;
31
32/** provides comprehensive information about the database as a whole.
33
34
35 <p>Many of the methods here return lists of information in
36 the form of
37 <type scope="com::sun::star::sdbc">XResultSet</type>
38 objects.
39 You can use the normal <type scope="com::sun::star::sdbc">XRow</type>
40 (or <type scope="com::sun::star::sdb">XColumn</type>)
41 methods such as
42 <member scope="com::sun::star::sdbc">XRow::getString()</member>
43 and
44 <member scope="com::sun::star::sdbc">XRow::getInt()</member>
45 to retrieve the data from these XResultSets. If a given form of
46 metadata is not available, these methods should throw a
47 <type scope="com::sun::star::sdbc">SQLException</type>
48 .
49 After calling one of the getXXX() methods,
50 one can check whether that value is <NULL/>
51 with the method <member scope="com::sun::star::sdbc">XRow::wasNull()</member>.
52 In the text only "(may be <NULL/>)" is mentioned for this case.
53 </p>
54 <p>Some of these methods take arguments that are String patterns. These
55 arguments all have names such as fooPattern. Within a pattern String, "%"
56 means match any substring of 0 or more characters, and "_" means match
57 any one character. Only metadata entries matching the search pattern
58 are returned. If a search pattern argument is set to <VOID/>,
59 that argument's criteria will be dropped from the search.
60 </p>
61 <p>
62 A
63 <type scope="com::sun::star::sdbc">SQLException</type>
64 will be thrown if a driver does not support
65 a metadata method. In the case of methods that return an XResultSet,
66 either an XResultSet (which may be empty) is returned or a
67 SQLException is thrown.</p>
68 */
69published interface XDatabaseMetaData: com::sun::star::uno::XInterface
70{
71
72 /** Can all the procedures returned by getProcedures be called by the
73 current user?
74
75 @return
76 <TRUE/>
77 if the user is allowed to call all procedures returned by getProcedures
78 otherwise
79 <FALSE/>
80 .
81 @throws SQLException
82 if a database access error occurs.
83 */
84 boolean allProceduresAreCallable() raises (SQLException);
85
86 /** Can all the tables returned by getTable be SELECTed by the
87 current user?
88 @returns
89 <TRUE/> if so
90 @throws SQLException
91 if a database access error occurs.
92 */
93 boolean allTablesAreSelectable() raises (SQLException);
94
95 /** returns the URL for the database connection
96 */
97 string getURL() raises (SQLException);
98
99 /** returns the user name from this database connection.
100 */
101 string getUserName() raises (SQLException);
102
103 /** checks if the database in read-only mode.
104 @returns
105 <TRUE/> if so
106 @throws SQLException
107 if a database access error occurs.
108 */
109 boolean isReadOnly() raises (SQLException);
110
111 /** Are NULL values sorted high?
112 @returns
113 <TRUE/> if so
114 @throws SQLException
115 if a database access error occurs.
116 */
117 boolean nullsAreSortedHigh() raises (SQLException);
118
119 /** Are NULL values sorted low?
120 @returns
121 <TRUE/> if so
122 @throws SQLException
123 if a database access error occurs.
124 */
125 boolean nullsAreSortedLow() raises (SQLException);
126
127 /** Are NULL values sorted at the start regardless of sort order?
128 @returns
129 <TRUE/> if so
130 @throws SQLException
131 if a database access error occurs.
132 */
133 boolean nullsAreSortedAtStart() raises (SQLException);
134
135 /** Are NULL values sorted at the end, regardless of sort order?
136 @returns
137 <TRUE/> if so
138 @throws SQLException
139 if a database access error occurs.
140 */
141 boolean nullsAreSortedAtEnd() raises (SQLException);
142
143 /** returns the name of the database product.
144 */
145 string getDatabaseProductName() raises (SQLException);
146
147 /** returns the version of the database product.
148 */
149 string getDatabaseProductVersion() raises (SQLException);
150
151 /** returns the name of the SDBC driver.
152 */
153 string getDriverName() raises (SQLException);
154
155 /** returns the version number of the SDBC driver.
156 */
157 string getDriverVersion() raises (SQLException);
158
159 /** returns the SDBC driver major version number.
160 */
161 long getDriverMajorVersion();
162
163 /** returns the SDBC driver minor version number.
164 */
165 long getDriverMinorVersion();
166
167 /** use the database local files to save the tables.
168 @returns
169 <TRUE/> if so
170 @throws SQLException
171 if a database access error occurs.
172 */
173 boolean usesLocalFiles() raises (SQLException);
174
175 /** use the database one local file to save for each table.
176 @returns
177 <TRUE/> if so
178 @throws SQLException
179 if a database access error occurs.
180 */
181 boolean usesLocalFilePerTable() raises (SQLException);
182
183 /** use the database "mixed case unquoted SQL identifiers" case sensitive.
184 @returns
185 <TRUE/> if so
186 @throws SQLException
187 if a database access error occurs.
188 */
189 boolean supportsMixedCaseIdentifiers() raises (SQLException);
190
191 /** Does the database treat mixed case unquoted SQL identifiers as
192 case insensitive and store them in upper case?
193 @returns
194 <TRUE/> if so
195 @throws SQLException
196 if a database access error occurs.
197 */
198 boolean storesUpperCaseIdentifiers() raises (SQLException);
199
200 /** Does the database treat mixed case unquoted SQL identifiers as
201 case insensitive and store them in lower case?
202 @returns
203 <TRUE/> if so
204 @throws SQLException
205 if a database access error occurs.
206 */
207 boolean storesLowerCaseIdentifiers() raises (SQLException);
208
209 /** Does the database treat mixed case unquoted SQL identifiers as
210 case insensitive and store them in mixed case?
211 @returns
212 <TRUE/> if so
213 @throws SQLException
214 if a database access error occurs.
215 */
216 boolean storesMixedCaseIdentifiers() raises (SQLException);
217
218 /** Does the database treat mixed case quoted SQL identifiers as
219 case sensitive and as a result store them in mixed case?
220 @returns
221 <TRUE/> if so
222 @throws SQLException
223 if a database access error occurs.
224 */
225 boolean supportsMixedCaseQuotedIdentifiers() raises (SQLException);
226
227 /** Does the database treat mixed case quoted SQL identifiers as
228 case insensitive and store them in upper case?
229 @returns
230 <TRUE/> if so
231 @throws SQLException
232 if a database access error occurs.
233 */
234 boolean storesUpperCaseQuotedIdentifiers() raises (SQLException);
235
236 /** Does the database treat mixed case quoted SQL identifiers as
237 case insensitive and store them in lower case?
238 @returns
239 <TRUE/> if so
240 @throws SQLException
241 if a database access error occurs.
242 */
243 boolean storesLowerCaseQuotedIdentifiers() raises (SQLException);
244
245 /** Does the database treat mixed case quoted SQL identifiers as
246 case insensitive and store them in mixed case?
247 @returns
248 <TRUE/> if so
249 @throws SQLException
250 if a database access error occurs.
251 */
252 boolean storesMixedCaseQuotedIdentifiers() raises (SQLException);
253
254 /** What's the string used to quote SQL identifiers?
255 This returns a space " " if identifier quoting is not supported.
256 @returns
257 <TRUE/> if so
258 @throws SQLException
259 if a database access error occurs.
260 */
261 string getIdentifierQuoteString() raises (SQLException);
262
263 /** gets a comma-separated list of all a database's SQL keywords
264 that are NOT also SQL92 keywords.
265 @returns
266 <TRUE/> if so
267 @throws SQLException
268 if a database access error occurs.
269 */
270 string getSQLKeywords() raises (SQLException);
271
272 /** gets a comma-separated list of math functions. These are the
273 X/Open CLI math function names used in the SDBC function escape
274 clause.
275 @returns
276 <TRUE/> if so
277 @throws SQLException
278 if a database access error occurs.
279 */
280 string getNumericFunctions() raises (SQLException);
281
282 /** gets a comma-separated list of string functions. These are the
283 X/Open CLI string function names used in the SDBC function escape
284 clause.
285 @returns
286 <TRUE/> if so
287 @throws SQLException
288 if a database access error occurs.
289 */
290 string getStringFunctions() raises (SQLException);
291
292 /** gets a comma-separated list of system functions. These are the
293 X/Open CLI system function names used in the SDBC function escape
294 clause.
295 @returns
296 <TRUE/> if so
297 @throws SQLException
298 if a database access error occurs.
299 */
300 string getSystemFunctions() raises (SQLException);
301
302 /** gets a comma-separated list of time and date functions.
303 @returns
304 <TRUE/> if so
305 @throws SQLException
306 if a database access error occurs.
307 */
308 string getTimeDateFunctions() raises (SQLException);
309
310 /** gets the string that can be used to escape wildcard characters.
311 This is the string that can be used to escape "_" or "%" in
312 the string pattern style catalog search parameters.
313
314
315 <p>
316 The "_" character represents any single character.
317 </p>
318 <p>
319 The "%" character represents any sequence of zero or
320 more characters.
321 </p>
322 @returns
323 <TRUE/> if so
324 @throws SQLException
325 if a database access error occurs.
326 */
327 string getSearchStringEscape() raises (SQLException);
328
329 /** gets all the "extra" characters that can be used in unquoted
330 identifier names (those beyond a-z, A-Z, 0-9 and _).
331 @returns
332 <TRUE/> if so
333 @throws SQLException
334 if a database access error occurs.
335 */
336 string getExtraNameCharacters() raises (SQLException);
337
338 /** support the Database "ALTER TABLE" with add column?
339 @returns
340 <TRUE/> if so
341 @throws SQLException
342 if a database access error occurs.
343 */
344 boolean supportsAlterTableWithAddColumn() raises (SQLException);
345
346 /** support the Database "ALTER TABLE" with drop column?
347 @returns
348 <TRUE/> if so
349 @throws SQLException
350 if a database access error occurs.
351 */
352 boolean supportsAlterTableWithDropColumn() raises (SQLException);
353
354 /** support the Database column aliasing?
355
356
357 <p>
358 The SQL AS clause can be used to provide names for
359 computed columns or to provide alias names for columns as required.
360 </p>
361 @returns
362 <TRUE/> if so
363 @throws SQLException
364 if a database access error occurs.
365 */
366 boolean supportsColumnAliasing() raises (SQLException);
367
368 /** are concatenations between NULL and non-NULL values NULL?
369 @returns
370 <TRUE/> if so
371 @throws SQLException
372 if a database access error occurs.
373 */
374 boolean nullPlusNonNullIsNull() raises (SQLException);
375
376 /** <TRUE/>
377 , if the Database supports the CONVERT function between SQL types,
378 otherwise
379 <FALSE/>
380 .
381 @returns
382 <TRUE/> if so
383 @throws SQLException
384 if a database access error occurs.
385 */
386 boolean supportsTypeConversion() raises (SQLException);
387
388 /** <TRUE/>
389 , if the Database supports the CONVERT between the given SQL types
390 otherwise
391 <FALSE/>
392 .
393 @returns
394 <TRUE/> if so
395 @throws SQLException
396 if a database access error occurs.
397 */
398 boolean supportsConvert([in]long fromType, [in]long toType)
399 raises (SQLException);
400
401 /** Are table correlation names supported?
402 @returns
403 <TRUE/> if so
404 @throws SQLException
405 if a database access error occurs.
406 */
407 boolean supportsTableCorrelationNames() raises (SQLException);
408
409 /** If table correlation names are supported, are they restricted
410 to be different from the names of the tables?
411 @returns
412 <TRUE/> if so
413 @throws SQLException
414 if a database access error occurs.
415 */
416 boolean supportsDifferentTableCorrelationNames()
417 raises (SQLException);
418
419 /** Are expressions in "ORDER BY" lists supported?
420 @returns
421 <TRUE/> if so
422 @throws SQLException
423 if a database access error occurs.
424 */
425 boolean supportsExpressionsInOrderBy() raises (SQLException);
426
427 /** Can an "ORDER BY" clause use columns not in the SELECT statement?
428 @returns
429 <TRUE/> if so
430 @throws SQLException
431 if a database access error occurs.
432 */
433 boolean supportsOrderByUnrelated() raises (SQLException);
434
435 /** Is some form of "GROUP BY" clause supported?
436 @returns
437 <TRUE/> if so
438 @throws SQLException
439 if a database access error occurs.
440 */
441 boolean supportsGroupBy() raises (SQLException);
442
443 /** Can a "GROUP BY" clause use columns not in the SELECT?
444 @returns
445 <TRUE/> if so
446 @throws SQLException
447 if a database access error occurs.
448 */
449 boolean supportsGroupByUnrelated() raises (SQLException);
450
451 /** Can a "GROUP BY" clause add columns not in the SELECT
452 provided it specifies all the columns in the SELECT?
453 @returns
454 <TRUE/> if so
455 @throws SQLException
456 if a database access error occurs.
457 */
458 boolean supportsGroupByBeyondSelect() raises (SQLException);
459
460 /** Is the escape character in "LIKE" clauses supported?
461 @returns
462 <TRUE/> if so
463 @throws SQLException
464 if a database access error occurs.
465 */
466 boolean supportsLikeEscapeClause() raises (SQLException);
467
468 /** Are multiple XResultSets from a single execute supported?
469 @returns
470 <TRUE/> if so
471 @throws SQLException
472 if a database access error occurs.
473 */
474 boolean supportsMultipleResultSets() raises (SQLException);
475
476 /** Can we have multiple transactions open at once (on different
477 connections)?
478 @returns
479 <TRUE/> if so
480 @throws SQLException
481 if a database access error occurs.
482 */
483 boolean supportsMultipleTransactions() raises (SQLException);
484
485 /** Can columns be defined as non-nullable?
486 @returns
487 <TRUE/> if so
488 @throws SQLException
489 if a database access error occurs.
490 */
491 boolean supportsNonNullableColumns() raises (SQLException);
492
493 /** <TRUE/>, if the database supports ODBC Minimum SQL grammar,
494 otherwise <FALSE/>.
495 @returns
496 <TRUE/> if so
497 @throws SQLException
498 if a database access error occurs.
499 */
500 boolean supportsMinimumSQLGrammar() raises (SQLException);
501
502 /** <TRUE/>, if the database supports ODBC Core SQL grammar,
503 otherwise <FALSE/>.
504 @returns
505 <TRUE/> if so
506 @throws SQLException
507 if a database access error occurs.
508 */
509 boolean supportsCoreSQLGrammar() raises (SQLException);
510
511 /**
512 <TRUE/>, if the database supports ODBC Extended SQL grammar,
513 otherwise <FALSE/>.
514 @returns
515 <TRUE/> if so
516 @throws SQLException
517 if a database access error occurs.
518 */
519 boolean supportsExtendedSQLGrammar() raises (SQLException);
520
521 /** @returns
522 <TRUE/>, if the database supports ANSI92 entry level SQL grammar,
523 otherwise <FALSE/>.
524 @throws SQLException
525 if a database access error occurs.
526 */
527 boolean supportsANSI92EntryLevelSQL() raises (SQLException);
528
529 /** @returns
530 <TRUE/>, if the database supports ANSI92 intermediate SQL grammar,
531 otherwise <FALSE/>.
532 @throws SQLException
533 if a database access error occurs.
534 */
535 boolean supportsANSI92IntermediateSQL() raises (SQLException);
536
537 /** @returns
538 <TRUE/>, if the database supports ANSI92 full SQL grammar,
539 otherwise <FALSE/>.
540 @throws SQLException
541 if a database access error occurs.
542 */
543 boolean supportsANSI92FullSQL() raises (SQLException);
544
545 /** returns
546 <TRUE/>, if the Database supports SQL Integrity Enhancement Facility,
547 otherwise <FALSE/>.
548 @throws SQLException
549 if a database access error occurs.
550 */
551 boolean supportsIntegrityEnhancementFacility() raises (SQLException);
552
553 /** @returns
554 <TRUE/>, if some form of outer join is supported,
555 otherwise <FALSE/>.
556 @throws SQLException
557 if a database access error occurs.
558 */
559 boolean supportsOuterJoins() raises (SQLException);
560
561 /** @returns
562 <TRUE/>, if full nested outer joins are supported,
563 otherwise <FALSE/>.
564 @throws SQLException
565 if a database access error occurs.
566 */
567 boolean supportsFullOuterJoins() raises (SQLException);
568
569 /** @returns
570 <TRUE/>, if there is limited support for outer joins.
571 (This will be <TRUE/> if supportFullOuterJoins is <TRUE/>.)
572 <FALSE/> is returned otherwise.
573 @throws SQLException
574 if a database access error occurs.
575 */
576 boolean supportsLimitedOuterJoins() raises (SQLException);
577
578 /** return the database vendor's preferred term for "schema"
579 @returns
580 <TRUE/> if so
581 @throws SQLException
582 if a database access error occurs.
583 */
584 string getSchemaTerm() raises (SQLException);
585
586 /** return the database vendor's preferred term for "procedure"
587 @returns
588 <TRUE/> if so
589 @throws SQLException
590 if a database access error occurs.
591 */
592 string getProcedureTerm() raises (SQLException);
593
594 /** return the database vendor's preferred term for "catalog"
595 @returns
596 <TRUE/> if so
597 @throws SQLException
598 if a database access error occurs.
599 */
600 string getCatalogTerm() raises (SQLException);
601
602 /** Does a catalog appear at the start of a qualified table name?
603 (Otherwise it appears at the end)
604 @returns
605 <TRUE/> if so
606 @throws SQLException
607 if a database access error occurs.
608 */
609 boolean isCatalogAtStart() raises (SQLException);
610
611 /** return the separator between catalog and table name
612 @returns
613 <TRUE/> if so
614 @throws SQLException
615 if a database access error occurs.
616 */
617 string getCatalogSeparator() raises (SQLException);
618
619 /** Can a schema name be used in a data manipulation statement?
620 @returns
621 <TRUE/> if so
622 @throws SQLException
623 if a database access error occurs.
624 */
625 boolean supportsSchemasInDataManipulation() raises (SQLException);
626
627 /** Can a schema name be used in a procedure call statement?
628 @returns
629 <TRUE/> if so
630 @throws SQLException
631 if a database access error occurs.
632 */
633 boolean supportsSchemasInProcedureCalls() raises (SQLException);
634
635 /** Can a schema name be used in a table definition statement?
636 @returns
637 <TRUE/> if so
638 @throws SQLException
639 if a database access error occurs.
640 */
641 boolean supportsSchemasInTableDefinitions() raises (SQLException);
642
643 /** Can a schema name be used in an index definition statement?
644 @returns
645 <TRUE/> if so
646 @throws SQLException
647 if a database access error occurs.
648 */
649 boolean supportsSchemasInIndexDefinitions() raises (SQLException);
650
651 /** Can a schema name be used in a privilege definition statement?
652 @returns
653 <TRUE/> if so
654 @throws SQLException
655 if a database access error occurs.
656 */
657 boolean supportsSchemasInPrivilegeDefinitions()
658 raises (SQLException);
659
660 /** Can a catalog name be used in a data manipulation statement?
661 @returns
662 <TRUE/> if so
663 @throws SQLException
664 if a database access error occurs.
665 */
666 boolean supportsCatalogsInDataManipulation() raises (SQLException);
667
668 /** Can a catalog name be used in a procedure call statement?
669 @returns
670 <TRUE/> if so
671 @throws SQLException
672 if a database access error occurs.
673 */
674 boolean supportsCatalogsInProcedureCalls() raises (SQLException);
675
676 /** Can a catalog name be used in a table definition statement?
677 @returns
678 <TRUE/> if so
679 @throws SQLException
680 if a database access error occurs.
681 */
682 boolean supportsCatalogsInTableDefinitions() raises (SQLException);
683
684 /** Can a catalog name be used in an index definition statement?
685 @returns
686 <TRUE/> if so
687 @throws SQLException
688 if a database access error occurs.
689 */
690 boolean supportsCatalogsInIndexDefinitions() raises (SQLException);
691
692 /** Can a catalog name be used in a privilege definition statement?
693 @returns
694 <TRUE/> if so
695 @throws SQLException
696 if a database access error occurs.
697 */
698 boolean supportsCatalogsInPrivilegeDefinitions()
699 raises (SQLException);
700
701 /** Is positioned DELETE supported?
702 @returns
703 <TRUE/> if so
704 @throws SQLException
705 if a database access error occurs.
706 */
707 boolean supportsPositionedDelete() raises (SQLException);
708
709 /** Is positioned UPDATE supported?
710 @returns
711 <TRUE/> if so
712 @throws SQLException
713 if a database access error occurs.
714 */
715 boolean supportsPositionedUpdate() raises (SQLException);
716
717 /** Is SELECT for UPDATE supported?
718 @returns
719 <TRUE/> if so
720 @throws SQLException
721 if a database access error occurs.
722 */
723 boolean supportsSelectForUpdate() raises (SQLException);
724
725 /** Are stored procedure calls using the stored procedure escape
726 syntax supported?
727 @returns
728 <TRUE/> if so
729 @throws SQLException
730 if a database access error occurs.
731 */
732 boolean supportsStoredProcedures() raises (SQLException);
733
734 /** Are subqueries in comparison expressions supported?
735 @returns
736 <TRUE/> if so
737 @throws SQLException
738 if a database access error occurs.
739 */
740 boolean supportsSubqueriesInComparisons() raises (SQLException);
741
742 /** Are subqueries in "exists" expressions supported?
743 @returns
744 <TRUE/> if so
745 @throws SQLException
746 if a database access error occurs.
747 */
748 boolean supportsSubqueriesInExists() raises (SQLException);
749
750 /** Are subqueries in "in" statements supported?
751 @returns
752 <TRUE/> if so
753 @throws SQLException
754 if a database access error occurs.
755 */
756 boolean supportsSubqueriesInIns() raises (SQLException);
757
758 /** Are subqueries in quantified expressions supported?
759 @returns
760 <TRUE/> if so
761 @throws SQLException
762 if a database access error occurs.
763 */
764 boolean supportsSubqueriesInQuantifieds() raises (SQLException);
765
766 /** Are correlated subqueries supported?
767 @returns
768 <TRUE/> if so
769 @throws SQLException
770 if a database access error occurs.
771 */
772 boolean supportsCorrelatedSubqueries() raises (SQLException);
773
774 /** Is SQL UNION supported?
775 @returns
776 <TRUE/> if so
777 @throws SQLException
778 if a database access error occurs.
779 */
780 boolean supportsUnion() raises (SQLException);
781
782 /** Is SQL UNION ALL supported?
783 @returns
784 <TRUE/> if so
785 @throws SQLException
786 if a database access error occurs.
787 */
788 boolean supportsUnionAll() raises (SQLException);
789
790 /** Can cursors remain open across commits?
791 @returns
792 <TRUE/> if so
793 @throws SQLException
794 if a database access error occurs.
795 */
796 boolean supportsOpenCursorsAcrossCommit() raises (SQLException);
797
798 /** Can cursors remain open across rollbacks?
799 @returns
800 <TRUE/> if so
801 @throws SQLException
802 if a database access error occurs.
803 */
804 boolean supportsOpenCursorsAcrossRollback() raises (SQLException);
805
806 /** Can statements remain open across commits?
807 @returns
808 <TRUE/> if so
809 @throws SQLException
810 if a database access error occurs.
811 */
812 boolean supportsOpenStatementsAcrossCommit() raises (SQLException);
813
814 /** Can statements remain open across rollbacks?
815 @returns
816 <TRUE/> if so
817 @throws SQLException
818 if a database access error occurs.
819 */
820 boolean supportsOpenStatementsAcrossRollback()
821 raises (SQLException);
822
823 /** return the maximal number of hex characters in an inline binary literal
824 @returns
825 <TRUE/> if so
826 @throws SQLException
827 if a database access error occurs.
828 */
829 long getMaxBinaryLiteralLength() raises (SQLException);
830
831 /** return the max length for a character literal
832 @returns
833 <TRUE/> if so
834 @throws SQLException
835 if a database access error occurs.
836 */
837 long getMaxCharLiteralLength() raises (SQLException);
838
839 /** return the limit on column name length
840 @returns
841 <TRUE/> if so
842 @throws SQLException
843 if a database access error occurs.
844 */
845 long getMaxColumnNameLength() raises (SQLException);
846
847 /** return the maximum number of columns in a "GROUP BY" clause
848 @returns
849 <TRUE/> if so
850 @throws SQLException
851 if a database access error occurs.
852 */
853 long getMaxColumnsInGroupBy() raises (SQLException);
854
855 /** return the maximum number of columns allowed in an index
856 @returns
857 <TRUE/> if so
858 @throws SQLException
859 if a database access error occurs.
860 */
861 long getMaxColumnsInIndex() raises (SQLException);
862
863 /** return the maximum number of columns in an "ORDER BY" clause
864 @returns
865 <TRUE/> if so
866 @throws SQLException
867 if a database access error occurs.
868 */
869 long getMaxColumnsInOrderBy() raises (SQLException);
870
871 /** return the maximum number of columns in a "SELECT" list
872 @returns
873 <TRUE/> if so
874 @throws SQLException
875 if a database access error occurs.
876 */
877 long getMaxColumnsInSelect() raises (SQLException);
878
879 /** return the maximum number of columns in a table
880 @returns
881 <TRUE/> if so
882 @throws SQLException
883 if a database access error occurs.
884 */
885 long getMaxColumnsInTable() raises (SQLException);
886
887 /** return the number of active connections at a time to this database.
888 @returns
889 <TRUE/> if so
890 @throws SQLException
891 if a database access error occurs.
892 */
893 long getMaxConnections() raises (SQLException);
894
895 /** return the maximum cursor name length
896 @returns
897 <TRUE/> if so
898 @throws SQLException
899 if a database access error occurs.
900 */
901 long getMaxCursorNameLength() raises (SQLException);
902
903 /** return the maximum length of an index (in bytes)
904 @returns
905 <TRUE/> if so
906 @throws SQLException
907 if a database access error occurs.
908 */
909 long getMaxIndexLength() raises (SQLException);
910
911 /** return the maximum length allowed for a schema name
912 @returns
913 <TRUE/> if so
914 @throws SQLException
915 if a database access error occurs.
916 */
917 long getMaxSchemaNameLength() raises (SQLException);
918
919 /** return the maximum length of a procedure name
920 @returns
921 <TRUE/> if so
922 @throws SQLException
923 if a database access error occurs.
924 */
925 long getMaxProcedureNameLength() raises (SQLException);
926
927 /** return the maximum length of a catalog name
928 @returns
929 <TRUE/> if so
930 @throws SQLException
931 if a database access error occurs.
932 */
933 long getMaxCatalogNameLength() raises (SQLException);
934
935 /** return the maximum length of a single row.
936 @returns
937 <TRUE/> if so
938 @throws SQLException
939 if a database access error occurs.
940 */
941 long getMaxRowSize() raises (SQLException);
942
943 /** Did getMaxRowSize() include LONGVARCHAR and LONGVARBINARY
944 blobs?
945 @returns
946 <TRUE/> if so
947 @throws SQLException
948 if a database access error occurs.
949 */
950 boolean doesMaxRowSizeIncludeBlobs() raises (SQLException);
951
952 /** return the maximum length of a SQL statement
953 @returns
954 <TRUE/> if so
955 @throws SQLException
956 if a database access error occurs.
957 */
958 long getMaxStatementLength() raises (SQLException);
959
960 /** return the maximal number of open active statements at one time to this database
961 @returns
962 <TRUE/> if so
963 @throws SQLException
964 if a database access error occurs.
965 */
966 long getMaxStatements() raises (SQLException);
967
968 /** return the maximum length of a table name
969 @returns
970 <TRUE/> if so
971 @throws SQLException
972 if a database access error occurs.
973 */
974 long getMaxTableNameLength() raises (SQLException);
975
976 /** return the maximum number of tables in a SELECT statement
977 @returns
978 <TRUE/> if so
979 @throws SQLException
980 if a database access error occurs.
981 */
982 long getMaxTablesInSelect() raises (SQLException);
983
984 /** return the maximum length of a user name
985 @returns
986 <TRUE/> if so
987 @throws SQLException
988 if a database access error occurs.
989 */
990 long getMaxUserNameLength() raises (SQLException);
991
992 /** return the database default transaction isolation level.
993 The values are defined in
994 <type scope="com::sun::star::sdbc">TransactionIsolation</type>.
995 @returns
996 <TRUE/> if so
997 @throws SQLException
998 if a database access error occurs.
999 @see com::sun::star::sdbc::XConnection
1000 */
1001 long getDefaultTransactionIsolation() raises (SQLException);
1002
1003 /** support the Database transactions?
1004 If not, invoking the method
1005 <member scope="com::sun::star::sdbc">XConnection::commit()</member>
1006 is a noop and the
1007 isolation level is TransactionIsolation_NONE.
1008 @returns
1009 <TRUE/> if so
1010 @throws SQLException
1011 if a database access error occurs.
1012 */
1013 boolean supportsTransactions() raises (SQLException);
1014
1015 /** Does this database support the given transaction isolation level?
1016 @returns
1017 <TRUE/> if so
1018 @throws SQLException
1019 if a database access error occurs.
1020 @see com::sun::star::sdbc::Connection
1021 */
1022 boolean supportsTransactionIsolationLevel([in]long level)
1023 raises (SQLException);
1024
1025 /** support the Database both data definition and data manipulation statements
1026 within a transaction?
1027 @returns
1028 <TRUE/> if so
1029 @throws SQLException
1030 if a database access error occurs.
1031<!-- JRH: Unclear on the intent of these many support questions.
1032 If asking, it should state, "Does the Database support both ....?
1033 If declaring, it should state something like the following:
1034
1035 metadata: supportsDataDefinitionAndDataManipulationTransactions
1036
1037 "provides support for both data definition and data manipulation statements within a transaction."
1038 --> */
1039 boolean supportsDataDefinitionAndDataManipulationTransactions()
1040 raises (SQLException);
1041
1042 /** are only data manipulation statements within a transaction
1043 supported?
1044 @returns
1045 <TRUE/> if so
1046 @throws SQLException
1047 if a database access error occurs.
1048 */
1049 boolean supportsDataManipulationTransactionsOnly()
1050 raises (SQLException);
1051
1052 /** does a data definition statement within a transaction force the
1053 transaction to commit?
1054 @returns
1055 <TRUE/> if so
1056 @throws SQLException
1057 if a database access error occurs.
1058 */
1059 boolean dataDefinitionCausesTransactionCommit()
1060 raises (SQLException);
1061
1062 /** is a data definition statement within a transaction ignored?
1063 @returns
1064 <TRUE/> if so
1065 @throws SQLException
1066 if a database access error occurs.
1067 */
1068 boolean dataDefinitionIgnoredInTransactions()
1069 raises (SQLException);
1070
1071 /** Gets a description of the stored procedures available in a
1072 catalog.
1073
1074
1075 <p>
1076 Only procedure descriptions matching the schema and
1077 procedure name criteria are returned. They are ordered by
1078 PROCEDURE_SCHEM, and PROCEDURE_NAME.
1079 </p>
1080 <p>
1081 Each procedure description has the following columns:
1082 </p>
1083 <ol>
1084 <li>
1085 <b>PROCEDURE_CAT</b> string => procedure catalog (may be <NULL/>)
1086 </li>
1087 <li>
1088 <b>PROCEDURE_SCHEM</b> string => procedure schema (may be <NULL/>)
1089 </li>
1090 <li>
1091 <b>PROCEDURE_NAME</b> string => procedure name
1092 </li>
1093 <li> reserved for future use
1094 </li>
1095 <li> reserved for future use
1096 </li>
1097 <li> reserved for future use
1098 </li>
1099 <li>
1100 <b>REMARKS</b> string => explanatory comment on the procedure
1101 </li>
1102 <li>
1103 <b>PROCEDURE_TYPE</b> short => kind of procedure:
1104 <ul>
1105 <li> UNKNOWN - May return a result
1106 </li>
1107 <li> NO - Does not return a result
1108 </li>
1109 <li> RETURN - Returns a result
1110 </li>
1111 </ul>
1112 </li>
1113 </ol>
1114 @param catalog
1115 a catalog name; "" retrieves those without a catalog; <VOID/> means drop catalog name from the selection criteria
1116 @param schemaPattern
1117 a schema name pattern; "" retrieves those without a schema
1118 @param procedureNamePattern
1119 a procedure name pattern
1120 @returns
1121 each row is a procedure description
1122 @throws SQLException
1123 if a database access error occurs.
1124 */
1125 XResultSet getProcedures([in]any catalog, [in]string schemaPattern,
1126 [in]string procedureNamePattern) raises (SQLException);
1127
1128 /** gets a description of a catalog's stored procedure parameters
1129 and result columns.
1130
1131
1132 <p>
1133 Only descriptions matching the schema, procedure and
1134 parameter name criteria are returned. They are ordered by
1135 PROCEDURE_SCHEM and PROCEDURE_NAME. Within this, the return value,
1136 if any, is first. Next are the parameter descriptions in call
1137 order. The column descriptions follow in column number order.
1138 </p>
1139 <p>Each row in the XResultSet is a parameter description or
1140 column description with the following fields:
1141 </p>
1142 <ol>
1143 <li>
1144 <b>PROCEDURE_CAT</b> string => procedure catalog (may be <NULL/>)
1145 </li>
1146 <li>
1147 <b>PROCEDURE_SCHEM</b> string => procedure schema (may be <NULL/>)
1148 </li>
1149 <li>
1150 <b>PROCEDURE_NAME</b> string => procedure name
1151 </li>
1152 <li>
1153 <b>COLUMN_NAME</b> string => column/parameter name
1154 </li>
1155 <li>
1156 <b>COLUMN_TYPE</b> Short => kind of column/parameter:
1157 <ul>
1158 <li> UNKNOWN - nobody knows
1159 </li>
1160 <li> IN - IN parameter
1161 </li>
1162 <li> INOUT - INOUT parameter
1163 </li>
1164 <li> OUT - OUT parameter
1165 </li>
1166 <li> RETURN - procedure return value
1167 </li>
1168 <li> RESULT - result column in XResultSet
1169 </li>
1170 </ul>
1171 </li>
1172 <li>
1173 <b>DATA_TYPE</b> short => SQL type from java.sql.Types
1174 </li>
1175 <li>
1176 <b>TYPE_NAME</b> string => SQL type name, for a UDT type the
1177 type name is fully qualified
1178 </li>
1179 <li>
1180 <b>PRECISION</b> long => precision
1181 </li>
1182 <li>
1183 <b>LENGTH</b> long => length in bytes of data
1184 </li>
1185 <li>
1186 <b>SCALE</b> short => scale
1187 </li>
1188 <li>
1189 <b>RADIX</b> short => radix
1190 </li>
1191 <li>
1192 <b>NULLABLE</b> short => can it contain NULL?
1193 <ul>
1194 <li> NO_NULLS - does not allow NULL values
1195 </li>
1196 <li> NULLABLE - allows NULL values
1197 </li>
1198 <li> NULLABLE_UNKNOWN - nullability unknown
1199 </li>
1200 </ul>
1201 </li>
1202 <li>
1203 <b>REMARKS</b> string => comment describing parameter/column
1204 </li>
1205 </ol>
1206 <p>
1207 <b>Note:</b> Some databases may not return the column
1208 descriptions for a procedure. Additional columns beyond
1209 REMARKS can be defined by the database.
1210 </p>
1211 @param catalog
1212 a catalog name; "" retrieves those without a catalog; <VOID/> means drop catalog name from the selection criteria
1213 @param schemaPattern
1214 a schema name pattern; "" retrieves those without a schema
1215 @param procedureNamePattern
1216 a procedure name pattern
1217 @param columnNamePattern
1218 a column name pattern
1219 @returns
1220 each row describes a stored procedure parameter or column
1221 @throws SQLException
1222 if a database access error occurs.
1223 */
1224 XResultSet getProcedureColumns([in]any catalog, [in]string schemaPattern,
1225 [in]string procedureNamePattern,
1226 [in]string columnNamePattern)
1227 raises (SQLException);
1228
1229 /** gets a description of tables available in a catalog.
1230
1231
1232 <p>Only table descriptions matching the catalog, schema, table
1233 name, and type criteria are returned. They are ordered by
1234 TABLE_TYPE, TABLE_SCHEM, and TABLE_NAME.
1235 </p>
1236 <p>Each table description has the following columns:
1237 </p>
1238 <ol>
1239 <li>
1240 <b>TABLE_CAT</b> string => table catalog (may be <NULL/>)
1241 </li>
1242 <li>
1243 <b>TABLE_SCHEM</b> string => table schema (may be <NULL/>)
1244 </li>
1245 <li>
1246 <b>TABLE_NAME</b> string => table name
1247 </li>
1248 <li>
1249 <b>TABLE_TYPE</b> string => table type. Typical types are "TABLE",
1250 "VIEW", "SYSTEM TABLE", "GLOBAL TEMPORARY",
1251 "LOCAL TEMPORARY", "ALIAS", "SYNONYM".
1252 </li>
1253 <li>
1254 <b>REMARKS</b> string => explanatory comment on the table
1255 </li>
1256 </ol>
1257 <p>
1258 <b>Note:</b> Some databases may not return information for
1259 all tables.
1260 </p>
1261 @param catalog
1262 a catalog name; "" retrieves those without a catalog; <VOID/> means drop catalog name from the selection criteria
1263 @param schemaPattern
1264 a schema name pattern; "" retrieves those without a schema
1265 @param tableNamePattern
1266 a table name pattern
1267 @param types
1268 a list of table types to include
1269 @returns
1270 each row is a table description
1271 @throws SQLException
1272 if a database access error occurs.
1273 */
1274 XResultSet getTables([in]any catalog, [in]string schemaPattern,
1275 [in]string tableNamePattern, [in]sequence<string> types)
1276 raises (SQLException);
1277
1278 /** Gets the schema names available in this database. The results
1279 are ordered by schema name.
1280
1281
1282 <p>The schema column is:
1283 </p>
1284 <ol>
1285 <li>
1286 <b>TABLE_SCHEM</b> string => schema name
1287 </li>
1288 </ol>
1289 @returns
1290 each row has a single String column that is a schema name
1291 @throws SQLException
1292 if a database access error occurs.
1293 */
1294 XResultSet getSchemas() raises (SQLException);
1295
1296 /** gets the catalog names available in this database. The results
1297 are ordered by catalog name.
1298
1299
1300 <p>The catalog column is:
1301 </p>
1302 <ol>
1303 <li>
1304 <b>TABLE_CAT</b> string => catalog name
1305 </li>
1306 </ol>
1307 @returns
1308 each row has a single String column that is a catalog name
1309 @throws SQLException
1310 if a database access error occurs.
1311 */
1312 XResultSet getCatalogs() raises (SQLException);
1313
1314 /** gets the table types available in this database. The results
1315 are ordered by table type.
1316
1317
1318 <p>The table type is:
1319 </p>
1320 <ol>
1321 <li>
1322 <b>TABLE_TYPE</b> string => table type. Typical types are "TABLE",
1323 "VIEW", "SYSTEM TABLE", "GLOBAL TEMPORARY",
1324 "LOCAL TEMPORARY", "ALIAS", "SYNONYM".
1325 </li>
1326 </ol>
1327 @returns
1328 each row has a single String column that is a table type
1329 @throws SQLException
1330 if a database access error occurs.
1331 */
1332 XResultSet getTableTypes() raises (SQLException);
1333
1334 /** gets a description of table columns available in
1335 the specified catalog.
1336
1337
1338 <p>Only column descriptions matching the catalog, schema, table
1339 and column name criteria are returned. They are ordered by
1340 TABLE_SCHEM, TABLE_NAME, and ORDINAL_POSITION.
1341 </p>
1342 <p>Each column description has the following columns:
1343 </p>
1344 <ol>
1345 <li>
1346 <b>TABLE_CAT</b> string => table catalog (may be <NULL/>)
1347 </li>
1348 <li>
1349 <b>TABLE_SCHEM</b> string => table schema (may be <NULL/>)
1350 </li>
1351 <li>
1352 <b>TABLE_NAME</b> string => table name
1353 </li>
1354 <li>
1355 <b>COLUMN_NAME</b> string => column name
1356 </li>
1357 <li>
1358 <b>DATA_TYPE</b> short => SQL type from java.sql.Types
1359 </li>
1360 <li>
1361 <b>TYPE_NAME</b> string => Data source dependent type name,
1362 for a UDT the type name is fully qualified
1363 </li>
1364 <li>
1365 <b>COLUMN_SIZE</b> long => column size. For char or date
1366 types this is the maximum number of characters, for numeric or
1367 decimal types this is precision.
1368 </li>
1369 <li>
1370 <b>BUFFER_LENGTH</b> is not used.
1371 </li>
1372 <li>
1373 <b>DECIMAL_DIGITS</b> long => the number of fractional digits
1374 </li>
1375 <li>
1376 <b>NUM_PREC_RADIX</b> long => Radix (typically either 10 or 2)
1377 </li>
1378 <li>
1379 <b>NULLABLE</b> long => is NULL allowed?
1380 <ul>
1381 <li> NO_NULLS - might not allow NULL values
1382 </li>
1383 <li> NULLABLE - definitely allows NULL values
1384 </li>
1385 <li> NULLABLE_UNKNOWN - nullability unknown
1386 </li>
1387 </ul>
1388 </li>
1389 <li>
1390 <b>REMARKS</b> string => comment describing column (may be <NULL/>)
1391 </li>
1392 <li>
1393 <b>COLUMN_DEF</b> string => default value (may be <NULL/>)
1394 </li>
1395 <li>
1396 <b>SQL_DATA_TYPE</b> long => unused
1397 </li>
1398 <li>
1399 <b>SQL_DATETIME_SUB</b> long => unused
1400 </li>
1401 <li>
1402 <b>CHAR_OCTET_LENGTH</b> long => for char types the
1403 maximum number of bytes in the column
1404 </li>
1405 <li>
1406 <b>ORDINAL_POSITION</b> int => index of column in table
1407 (starting at 1)
1408 </li>
1409 <li>
1410 <b>IS_NULLABLE</b> string => "NO" means column definitely
1411 does not allow NULL values; "YES" means the column might
1412 allow NULL values. An empty string means nobody knows.
1413 </li>
1414 </ol>
1415 @param catalog
1416 a catalog name; "" retrieves those without a catalog; <VOID/> means drop catalog name from the selection criteria
1417 @param schemaPattern
1418 a schema name pattern; "" retrieves those without a schema
1419 @param tableNamePattern
1420 a table name pattern
1421 @param columnNamePattern
1422 a column name pattern
1423 @returns
1424 each row is a column description
1425 @throws SQLException
1426 if a database access error occurs.
1427 */
1428 XResultSet getColumns([in]any catalog, [in]string schemaPattern,
1429 [in]string tableNamePattern, [in]string columnNamePattern)
1430 raises (SQLException);
1431
1432 /** gets a description of the access rights for a table's columns.
1433
1434
1435 <p>
1436 Only privileges matching the column name criteria are
1437 returned. They are ordered by COLUMN_NAME and PRIVILEGE.
1438 </p>
1439 <p>Each privilege description has the following columns:
1440 </p>
1441 <ol>
1442 <li>
1443 <b>TABLE_CAT</b> string => table catalog (may be <NULL/>)
1444 </li>
1445 <li>
1446 <b>TABLE_SCHEM</b> string => table schema (may be <NULL/>)
1447 </li>
1448 <li>
1449 <b>TABLE_NAME</b> string => table name
1450 </li>
1451 <li>
1452 <b>COLUMN_NAME</b> string => column name
1453 </li>
1454 <li>
1455 <b>GRANTOR</b> => granter of access (may be <NULL/>)
1456 </li>
1457 <li>
1458 <b>GRANTEE</b> string => grantee of access
1459 </li>
1460 <li>
1461 <b>PRIVILEGE</b> string => name of access (SELECT,
1462 INSERT, UPDATE, REFERENCES, ...)
1463 </li>
1464 <li>
1465 <b>IS_GRANTABLE</b> string => "YES" if grantee is permitted
1466 to grant to others; "NO" if not; <NULL/> if unknown
1467 </li>
1468 </ol>
1469 @param catalog
1470 a catalog name; "" retrieves those without a catalog; <VOID/> means drop catalog name from the selection criteria
1471 @param schema
1472 a schema name ; "" retrieves those without a schema
1473 @param table
1474 a table name
1475 @param columnNamePattern
1476 a column name pattern
1477 @returns
1478 each row is a column privilege description
1479 @throws SQLException
1480 if a database access error occurs.
1481 */
1482 XResultSet getColumnPrivileges([in]any catalog, [in]string schema,
1483 [in]string table, [in]string columnNamePattern) raises (SQLException);
1484
1485 /** gets a description of the access rights for each table available
1486 in a catalog. Note that a table privilege applies to one or
1487 more columns in the table. It would be wrong to assume that
1488 this privilege applies to all columns (this may be <TRUE/> for
1489 some systems but is not <TRUE/> for all.)
1490
1491
1492 <p>Only privileges matching the schema and table name
1493 criteria are returned. They are ordered by TABLE_SCHEM,
1494 TABLE_NAME, and PRIVILEGE.
1495 </p>
1496 <p>Each privilege description has the following columns:
1497 </p>
1498 <ol>
1499 <li>
1500 <b>TABLE_CAT</b> string => table catalog (may be <NULL/>)
1501 </li>
1502 <li>
1503 <b>TABLE_SCHEM</b> string => table schema (may be <NULL/>)
1504 </li>
1505 <li>
1506 <b>TABLE_NAME</b> string => table name
1507 </li>
1508 <li>
1509 <b>GRANTOR</b> => granter of access (may be <NULL/>)
1510 </li>
1511 <li>
1512 <b>GRANTEE</b> string => grantee of access
1513 </li>
1514 <li>
1515 <b>PRIVILEGE</b> string => name of access (SELECT,
1516 INSERT, UPDATE, REFERENCES, ...)
1517 </li>
1518 <li>
1519 <b>IS_GRANTABLE</b> string => "YES" if grantee is permitted
1520 to grant to others; "NO" if not; <NULL/> if unknown
1521 </li>
1522 </ol>
1523 @param catalog
1524 a catalog name; "" retrieves those without a catalog; <VOID/> means drop catalog name from the selection criteria
1525 @param schemaPattern
1526 a schema name pattern; "" retrieves those without a schema
1527 @param tableNamePattern
1528 a tab…
Large files files are truncated, but you can click here to view the full file