src/java.sql/share/classes/java/sql/DatabaseMetaData.java
author alanb
Tue, 15 May 2018 09:33:02 +0100
changeset 50109 ea54197f4fe4
parent 47216 71c04702a3d5
permissions -rw-r--r--
8203059: (so) Closing a socket channel registered with Selector and with SO_LINGER set to 0 does not reset connection Reviewed-by: chegar
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     1
/*
45331
f829a12aff54 8180728: DatabaseMeta.getRowIdLifetime returns an enum but javadoc refers to int
lancea
parents: 44256
diff changeset
     2
 * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
90ce3da70b43 Initial load
duke
parents:
diff changeset
     4
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
90ce3da70b43 Initial load
duke
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
     7
 * published by the Free Software Foundation.  Oracle designates this
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
     9
 * by Oracle in the LICENSE file that accompanied this code.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    10
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
90ce3da70b43 Initial load
duke
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
90ce3da70b43 Initial load
duke
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
90ce3da70b43 Initial load
duke
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
90ce3da70b43 Initial load
duke
parents:
diff changeset
    15
 * accompanied this code).
90ce3da70b43 Initial load
duke
parents:
diff changeset
    16
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
90ce3da70b43 Initial load
duke
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    20
 *
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    21
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    22
 * or visit www.oracle.com if you need additional information or have any
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    23
 * questions.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    24
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    25
90ce3da70b43 Initial load
duke
parents:
diff changeset
    26
90ce3da70b43 Initial load
duke
parents:
diff changeset
    27
package java.sql;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    28
90ce3da70b43 Initial load
duke
parents:
diff changeset
    29
/**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    30
 * Comprehensive information about the database as a whole.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    31
 * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    32
 * This interface is implemented by driver vendors to let users know the capabilities
90ce3da70b43 Initial load
duke
parents:
diff changeset
    33
 * of a Database Management System (DBMS) in combination with
18564
f9db68ff2cbb 8017471: Fix JDBC -Xdoclint public errors
lancea
parents: 18156
diff changeset
    34
 * the driver based on JDBC&trade; technology
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    35
 * ("JDBC driver") that is used with it.  Different relational DBMSs often support
90ce3da70b43 Initial load
duke
parents:
diff changeset
    36
 * different features, implement features in different ways, and use different
90ce3da70b43 Initial load
duke
parents:
diff changeset
    37
 * data types.  In addition, a driver may implement a feature on top of what the
90ce3da70b43 Initial load
duke
parents:
diff changeset
    38
 * DBMS offers.  Information returned by methods in this interface applies
90ce3da70b43 Initial load
duke
parents:
diff changeset
    39
 * to the capabilities of a particular driver and a particular DBMS working
90ce3da70b43 Initial load
duke
parents:
diff changeset
    40
 * together. Note that as used in this documentation, the term "database" is
90ce3da70b43 Initial load
duke
parents:
diff changeset
    41
 * used generically to refer to both the driver and DBMS.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    42
 * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    43
 * A user for this interface is commonly a tool that needs to discover how to
90ce3da70b43 Initial load
duke
parents:
diff changeset
    44
 * deal with the underlying DBMS.  This is especially true for applications
90ce3da70b43 Initial load
duke
parents:
diff changeset
    45
 * that are intended to be used with more than one DBMS. For example, a tool might use the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
    46
 * <code>getTypeInfo</code> to find out what data types can be used in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
    47
 * <code>CREATE TABLE</code> statement.  Or a user might call the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
    48
 * <code>supportsCorrelatedSubqueries</code> to see if it is possible to use
90ce3da70b43 Initial load
duke
parents:
diff changeset
    49
 * a correlated subquery or <code>supportsBatchUpdates</code> to see if it is
90ce3da70b43 Initial load
duke
parents:
diff changeset
    50
 * possible to use batch updates.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    51
 * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    52
 * Some <code>DatabaseMetaData</code> methods return lists of information
90ce3da70b43 Initial load
duke
parents:
diff changeset
    53
 * in the form of <code>ResultSet</code> objects.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    54
 * Regular <code>ResultSet</code> methods, such as
90ce3da70b43 Initial load
duke
parents:
diff changeset
    55
 * <code>getString</code> and <code>getInt</code>, can be used
90ce3da70b43 Initial load
duke
parents:
diff changeset
    56
 * to retrieve the data from these <code>ResultSet</code> objects.  If
90ce3da70b43 Initial load
duke
parents:
diff changeset
    57
 * a given form of metadata is not available, an empty <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    58
 * will be returned. Additional columns beyond the columns defined to be
90ce3da70b43 Initial load
duke
parents:
diff changeset
    59
 * returned by the <code>ResultSet</code> object for a given method
90ce3da70b43 Initial load
duke
parents:
diff changeset
    60
 * can be defined by the JDBC driver vendor and must be accessed
90ce3da70b43 Initial load
duke
parents:
diff changeset
    61
 * by their <B>column label</B>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    62
 * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    63
 * Some <code>DatabaseMetaData</code> methods take arguments that are
90ce3da70b43 Initial load
duke
parents:
diff changeset
    64
 * String patterns.  These arguments all have names such as fooPattern.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    65
 * Within a pattern String, "%" means match any substring of 0 or more
90ce3da70b43 Initial load
duke
parents:
diff changeset
    66
 * characters, and "_" means match any one character. Only metadata
90ce3da70b43 Initial load
duke
parents:
diff changeset
    67
 * entries matching the search pattern are returned. If a search pattern
90ce3da70b43 Initial load
duke
parents:
diff changeset
    68
 * argument is set to <code>null</code>, that argument's criterion will
90ce3da70b43 Initial load
duke
parents:
diff changeset
    69
 * be dropped from the search.
20880
1b610151b316 8026812: doclint clean up for java.sql and javax.sql
lancea
parents: 18564
diff changeset
    70
 *
44256
12050b22e372 8176721: @since value errors java.sql module
mli
parents: 35302
diff changeset
    71
 * @since 1.1
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    72
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    73
public interface DatabaseMetaData extends Wrapper {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    74
90ce3da70b43 Initial load
duke
parents:
diff changeset
    75
    //----------------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
    76
    // First, a variety of minor information about the target database.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    77
90ce3da70b43 Initial load
duke
parents:
diff changeset
    78
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    79
     * Retrieves whether the current user can call all the procedures
90ce3da70b43 Initial load
duke
parents:
diff changeset
    80
     * returned by the method <code>getProcedures</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    81
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    82
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
    83
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
    84
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    85
    boolean allProceduresAreCallable() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    86
90ce3da70b43 Initial load
duke
parents:
diff changeset
    87
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    88
     * Retrieves whether the current user can use all the tables returned
90ce3da70b43 Initial load
duke
parents:
diff changeset
    89
     * by the method <code>getTables</code> in a <code>SELECT</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    90
     * statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    91
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    92
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
    93
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
    94
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    95
    boolean allTablesAreSelectable() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    96
90ce3da70b43 Initial load
duke
parents:
diff changeset
    97
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    98
     * Retrieves the URL for this DBMS.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    99
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   100
     * @return the URL for this DBMS or <code>null</code> if it cannot be
90ce3da70b43 Initial load
duke
parents:
diff changeset
   101
     *          generated
90ce3da70b43 Initial load
duke
parents:
diff changeset
   102
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   103
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   104
    String getURL() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   105
90ce3da70b43 Initial load
duke
parents:
diff changeset
   106
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   107
     * Retrieves the user name as known to this database.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   108
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   109
     * @return the database user name
90ce3da70b43 Initial load
duke
parents:
diff changeset
   110
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   111
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   112
    String getUserName() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   113
90ce3da70b43 Initial load
duke
parents:
diff changeset
   114
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   115
     * Retrieves whether this database is in read-only mode.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   116
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   117
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   118
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   119
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   120
    boolean isReadOnly() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   121
90ce3da70b43 Initial load
duke
parents:
diff changeset
   122
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   123
     * Retrieves whether <code>NULL</code> values are sorted high.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   124
     * Sorted high means that <code>NULL</code> values
90ce3da70b43 Initial load
duke
parents:
diff changeset
   125
     * sort higher than any other value in a domain.  In an ascending order,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   126
     * if this method returns <code>true</code>,  <code>NULL</code> values
90ce3da70b43 Initial load
duke
parents:
diff changeset
   127
     * will appear at the end. By contrast, the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
   128
     * <code>nullsAreSortedAtEnd</code> indicates whether <code>NULL</code> values
90ce3da70b43 Initial load
duke
parents:
diff changeset
   129
     * are sorted at the end regardless of sort order.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   130
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   131
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   132
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   133
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   134
    boolean nullsAreSortedHigh() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   135
90ce3da70b43 Initial load
duke
parents:
diff changeset
   136
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   137
     * Retrieves whether <code>NULL</code> values are sorted low.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   138
     * Sorted low means that <code>NULL</code> values
90ce3da70b43 Initial load
duke
parents:
diff changeset
   139
     * sort lower than any other value in a domain.  In an ascending order,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   140
     * if this method returns <code>true</code>,  <code>NULL</code> values
90ce3da70b43 Initial load
duke
parents:
diff changeset
   141
     * will appear at the beginning. By contrast, the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
   142
     * <code>nullsAreSortedAtStart</code> indicates whether <code>NULL</code> values
90ce3da70b43 Initial load
duke
parents:
diff changeset
   143
     * are sorted at the beginning regardless of sort order.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   144
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   145
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   146
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   147
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   148
    boolean nullsAreSortedLow() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   149
90ce3da70b43 Initial load
duke
parents:
diff changeset
   150
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   151
     * Retrieves whether <code>NULL</code> values are sorted at the start regardless
90ce3da70b43 Initial load
duke
parents:
diff changeset
   152
     * of sort order.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   153
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   154
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   155
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   156
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   157
    boolean nullsAreSortedAtStart() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   158
90ce3da70b43 Initial load
duke
parents:
diff changeset
   159
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   160
     * Retrieves whether <code>NULL</code> values are sorted at the end regardless of
90ce3da70b43 Initial load
duke
parents:
diff changeset
   161
     * sort order.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   162
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   163
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   164
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   165
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   166
    boolean nullsAreSortedAtEnd() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   167
90ce3da70b43 Initial load
duke
parents:
diff changeset
   168
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   169
     * Retrieves the name of this database product.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   170
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   171
     * @return database product name
90ce3da70b43 Initial load
duke
parents:
diff changeset
   172
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   173
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   174
    String getDatabaseProductName() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   175
90ce3da70b43 Initial load
duke
parents:
diff changeset
   176
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   177
     * Retrieves the version number of this database product.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   178
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   179
     * @return database version number
90ce3da70b43 Initial load
duke
parents:
diff changeset
   180
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   181
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   182
    String getDatabaseProductVersion() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   183
90ce3da70b43 Initial load
duke
parents:
diff changeset
   184
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   185
     * Retrieves the name of this JDBC driver.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   186
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   187
     * @return JDBC driver name
90ce3da70b43 Initial load
duke
parents:
diff changeset
   188
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   189
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   190
    String getDriverName() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   191
90ce3da70b43 Initial load
duke
parents:
diff changeset
   192
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   193
     * Retrieves the version number of this JDBC driver as a <code>String</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   194
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   195
     * @return JDBC driver version
90ce3da70b43 Initial load
duke
parents:
diff changeset
   196
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   197
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   198
    String getDriverVersion() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   199
90ce3da70b43 Initial load
duke
parents:
diff changeset
   200
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   201
     * Retrieves this JDBC driver's major version number.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   202
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   203
     * @return JDBC driver major version
90ce3da70b43 Initial load
duke
parents:
diff changeset
   204
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   205
    int getDriverMajorVersion();
90ce3da70b43 Initial load
duke
parents:
diff changeset
   206
90ce3da70b43 Initial load
duke
parents:
diff changeset
   207
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   208
     * Retrieves this JDBC driver's minor version number.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   209
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   210
     * @return JDBC driver minor version number
90ce3da70b43 Initial load
duke
parents:
diff changeset
   211
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   212
    int getDriverMinorVersion();
90ce3da70b43 Initial load
duke
parents:
diff changeset
   213
90ce3da70b43 Initial load
duke
parents:
diff changeset
   214
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   215
     * Retrieves whether this database stores tables in a local file.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   216
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   217
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   218
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   219
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   220
    boolean usesLocalFiles() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   221
90ce3da70b43 Initial load
duke
parents:
diff changeset
   222
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   223
     * Retrieves whether this database uses a file for each table.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   224
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   225
     * @return <code>true</code> if this database uses a local file for each table;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   226
     *         <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   227
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   228
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   229
    boolean usesLocalFilePerTable() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   230
90ce3da70b43 Initial load
duke
parents:
diff changeset
   231
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   232
     * Retrieves whether this database treats mixed case unquoted SQL identifiers as
90ce3da70b43 Initial load
duke
parents:
diff changeset
   233
     * case sensitive and as a result stores them in mixed case.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   234
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   235
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   236
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   237
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   238
    boolean supportsMixedCaseIdentifiers() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   239
90ce3da70b43 Initial load
duke
parents:
diff changeset
   240
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   241
     * Retrieves whether this database treats mixed case unquoted SQL identifiers as
90ce3da70b43 Initial load
duke
parents:
diff changeset
   242
     * case insensitive and stores them in upper case.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   243
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   244
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   245
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   246
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   247
    boolean storesUpperCaseIdentifiers() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   248
90ce3da70b43 Initial load
duke
parents:
diff changeset
   249
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   250
     * Retrieves whether this database treats mixed case unquoted SQL identifiers as
90ce3da70b43 Initial load
duke
parents:
diff changeset
   251
     * case insensitive and stores them in lower case.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   252
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   253
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   254
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   255
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   256
    boolean storesLowerCaseIdentifiers() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   257
90ce3da70b43 Initial load
duke
parents:
diff changeset
   258
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   259
     * Retrieves whether this database treats mixed case unquoted SQL identifiers as
90ce3da70b43 Initial load
duke
parents:
diff changeset
   260
     * case insensitive and stores them in mixed case.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   261
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   262
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   263
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   264
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   265
    boolean storesMixedCaseIdentifiers() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   266
90ce3da70b43 Initial load
duke
parents:
diff changeset
   267
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   268
     * Retrieves whether this database treats mixed case quoted SQL identifiers as
90ce3da70b43 Initial load
duke
parents:
diff changeset
   269
     * case sensitive and as a result stores them in mixed case.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   270
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   271
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   272
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   273
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   274
    boolean supportsMixedCaseQuotedIdentifiers() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   275
90ce3da70b43 Initial load
duke
parents:
diff changeset
   276
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   277
     * Retrieves whether this database treats mixed case quoted SQL identifiers as
90ce3da70b43 Initial load
duke
parents:
diff changeset
   278
     * case insensitive and stores them in upper case.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   279
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   280
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   281
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   282
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   283
    boolean storesUpperCaseQuotedIdentifiers() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   284
90ce3da70b43 Initial load
duke
parents:
diff changeset
   285
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   286
     * Retrieves whether this database treats mixed case quoted SQL identifiers as
90ce3da70b43 Initial load
duke
parents:
diff changeset
   287
     * case insensitive and stores them in lower case.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   288
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   289
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   290
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   291
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   292
    boolean storesLowerCaseQuotedIdentifiers() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   293
90ce3da70b43 Initial load
duke
parents:
diff changeset
   294
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   295
     * Retrieves whether this database treats mixed case quoted SQL identifiers as
90ce3da70b43 Initial load
duke
parents:
diff changeset
   296
     * case insensitive and stores them in mixed case.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   297
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   298
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   299
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   300
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   301
    boolean storesMixedCaseQuotedIdentifiers() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   302
90ce3da70b43 Initial load
duke
parents:
diff changeset
   303
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   304
     * Retrieves the string used to quote SQL identifiers.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   305
     * This method returns a space " " if identifier quoting is not supported.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   306
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   307
     * @return the quoting string or a space if quoting is not supported
90ce3da70b43 Initial load
duke
parents:
diff changeset
   308
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   309
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   310
    String getIdentifierQuoteString() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   311
90ce3da70b43 Initial load
duke
parents:
diff changeset
   312
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   313
     * Retrieves a comma-separated list of all of this database's SQL keywords
90ce3da70b43 Initial load
duke
parents:
diff changeset
   314
     * that are NOT also SQL:2003 keywords.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   315
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   316
     * @return the list of this database's keywords that are not also
90ce3da70b43 Initial load
duke
parents:
diff changeset
   317
     *         SQL:2003 keywords
90ce3da70b43 Initial load
duke
parents:
diff changeset
   318
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   319
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   320
    String getSQLKeywords() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   321
90ce3da70b43 Initial load
duke
parents:
diff changeset
   322
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   323
     * Retrieves a comma-separated list of math functions available with
90ce3da70b43 Initial load
duke
parents:
diff changeset
   324
     * this database.  These are the Open /Open CLI math function names used in
90ce3da70b43 Initial load
duke
parents:
diff changeset
   325
     * the JDBC function escape clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   326
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   327
     * @return the list of math functions supported by this database
90ce3da70b43 Initial load
duke
parents:
diff changeset
   328
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   329
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   330
    String getNumericFunctions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   331
90ce3da70b43 Initial load
duke
parents:
diff changeset
   332
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   333
     * Retrieves a comma-separated list of string functions available with
90ce3da70b43 Initial load
duke
parents:
diff changeset
   334
     * this database.  These are the  Open Group CLI string function names used
90ce3da70b43 Initial load
duke
parents:
diff changeset
   335
     * in the JDBC function escape clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   336
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   337
     * @return the list of string functions supported by this database
90ce3da70b43 Initial load
duke
parents:
diff changeset
   338
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   339
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   340
    String getStringFunctions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   341
90ce3da70b43 Initial load
duke
parents:
diff changeset
   342
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   343
     * Retrieves a comma-separated list of system functions available with
90ce3da70b43 Initial load
duke
parents:
diff changeset
   344
     * this database.  These are the  Open Group CLI system function names used
90ce3da70b43 Initial load
duke
parents:
diff changeset
   345
     * in the JDBC function escape clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   346
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   347
     * @return a list of system functions supported by this database
90ce3da70b43 Initial load
duke
parents:
diff changeset
   348
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   349
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   350
    String getSystemFunctions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   351
90ce3da70b43 Initial load
duke
parents:
diff changeset
   352
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   353
     * Retrieves a comma-separated list of the time and date functions available
90ce3da70b43 Initial load
duke
parents:
diff changeset
   354
     * with this database.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   355
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   356
     * @return the list of time and date functions supported by this database
90ce3da70b43 Initial load
duke
parents:
diff changeset
   357
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   358
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   359
    String getTimeDateFunctions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   360
90ce3da70b43 Initial load
duke
parents:
diff changeset
   361
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   362
     * Retrieves the string that can be used to escape wildcard characters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   363
     * This is the string that can be used to escape '_' or '%' in
90ce3da70b43 Initial load
duke
parents:
diff changeset
   364
     * the catalog search parameters that are a pattern (and therefore use one
90ce3da70b43 Initial load
duke
parents:
diff changeset
   365
     * of the wildcard characters).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   366
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   367
     * <P>The '_' character represents any single character;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   368
     * the '%' character represents any sequence of zero or
90ce3da70b43 Initial load
duke
parents:
diff changeset
   369
     * more characters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   370
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   371
     * @return the string used to escape wildcard characters
90ce3da70b43 Initial load
duke
parents:
diff changeset
   372
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   373
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   374
    String getSearchStringEscape() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   375
90ce3da70b43 Initial load
duke
parents:
diff changeset
   376
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   377
     * Retrieves all the "extra" characters that can be used in unquoted
90ce3da70b43 Initial load
duke
parents:
diff changeset
   378
     * identifier names (those beyond a-z, A-Z, 0-9 and _).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   379
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   380
     * @return the string containing the extra characters
90ce3da70b43 Initial load
duke
parents:
diff changeset
   381
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   382
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   383
    String getExtraNameCharacters() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   384
90ce3da70b43 Initial load
duke
parents:
diff changeset
   385
    //--------------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   386
    // Functions describing which features are supported.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   387
90ce3da70b43 Initial load
duke
parents:
diff changeset
   388
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   389
     * Retrieves whether this database supports <code>ALTER TABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   390
     * with add column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   391
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   392
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   393
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   394
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   395
    boolean supportsAlterTableWithAddColumn() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   396
90ce3da70b43 Initial load
duke
parents:
diff changeset
   397
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   398
     * Retrieves whether this database supports <code>ALTER TABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   399
     * with drop column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   400
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   401
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   402
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   403
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   404
    boolean supportsAlterTableWithDropColumn() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   405
90ce3da70b43 Initial load
duke
parents:
diff changeset
   406
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   407
     * Retrieves whether this database supports column aliasing.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   408
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   409
     * <P>If so, the SQL AS clause can be used to provide names for
90ce3da70b43 Initial load
duke
parents:
diff changeset
   410
     * computed columns or to provide alias names for columns as
90ce3da70b43 Initial load
duke
parents:
diff changeset
   411
     * required.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   412
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   413
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   414
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   415
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   416
    boolean supportsColumnAliasing() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   417
90ce3da70b43 Initial load
duke
parents:
diff changeset
   418
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   419
     * Retrieves whether this database supports concatenations between
90ce3da70b43 Initial load
duke
parents:
diff changeset
   420
     * <code>NULL</code> and non-<code>NULL</code> values being
90ce3da70b43 Initial load
duke
parents:
diff changeset
   421
     * <code>NULL</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   422
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   423
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   424
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   425
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   426
    boolean nullPlusNonNullIsNull() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   427
90ce3da70b43 Initial load
duke
parents:
diff changeset
   428
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   429
     * Retrieves whether this database supports the JDBC scalar function
90ce3da70b43 Initial load
duke
parents:
diff changeset
   430
     * <code>CONVERT</code> for the conversion of one JDBC type to another.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   431
     * The JDBC types are the generic SQL data types defined
90ce3da70b43 Initial load
duke
parents:
diff changeset
   432
     * in <code>java.sql.Types</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   433
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   434
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   435
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   436
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   437
    boolean supportsConvert() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   438
90ce3da70b43 Initial load
duke
parents:
diff changeset
   439
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   440
     * Retrieves whether this database supports the JDBC scalar function
90ce3da70b43 Initial load
duke
parents:
diff changeset
   441
     * <code>CONVERT</code> for conversions between the JDBC types <i>fromType</i>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   442
     * and <i>toType</i>.  The JDBC types are the generic SQL data types defined
90ce3da70b43 Initial load
duke
parents:
diff changeset
   443
     * in <code>java.sql.Types</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   444
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   445
     * @param fromType the type to convert from; one of the type codes from
90ce3da70b43 Initial load
duke
parents:
diff changeset
   446
     *        the class <code>java.sql.Types</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   447
     * @param toType the type to convert to; one of the type codes from
90ce3da70b43 Initial load
duke
parents:
diff changeset
   448
     *        the class <code>java.sql.Types</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   449
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   450
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   451
     * @see Types
90ce3da70b43 Initial load
duke
parents:
diff changeset
   452
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   453
    boolean supportsConvert(int fromType, int toType) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   454
90ce3da70b43 Initial load
duke
parents:
diff changeset
   455
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   456
     * Retrieves whether this database supports table correlation names.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   457
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   458
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   459
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   460
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   461
    boolean supportsTableCorrelationNames() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   462
90ce3da70b43 Initial load
duke
parents:
diff changeset
   463
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   464
     * Retrieves whether, when table correlation names are supported, they
90ce3da70b43 Initial load
duke
parents:
diff changeset
   465
     * are restricted to being different from the names of the tables.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   466
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   467
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   468
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   469
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   470
    boolean supportsDifferentTableCorrelationNames() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   471
90ce3da70b43 Initial load
duke
parents:
diff changeset
   472
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   473
     * Retrieves whether this database supports expressions in
90ce3da70b43 Initial load
duke
parents:
diff changeset
   474
     * <code>ORDER BY</code> lists.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   475
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   476
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   477
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   478
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   479
    boolean supportsExpressionsInOrderBy() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   480
90ce3da70b43 Initial load
duke
parents:
diff changeset
   481
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   482
     * Retrieves whether this database supports using a column that is
90ce3da70b43 Initial load
duke
parents:
diff changeset
   483
     * not in the <code>SELECT</code> statement in an
90ce3da70b43 Initial load
duke
parents:
diff changeset
   484
     * <code>ORDER BY</code> clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   485
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   486
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   487
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   488
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   489
    boolean supportsOrderByUnrelated() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   490
90ce3da70b43 Initial load
duke
parents:
diff changeset
   491
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   492
     * Retrieves whether this database supports some form of
90ce3da70b43 Initial load
duke
parents:
diff changeset
   493
     * <code>GROUP BY</code> clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   494
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   495
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   496
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   497
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   498
    boolean supportsGroupBy() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   499
90ce3da70b43 Initial load
duke
parents:
diff changeset
   500
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   501
     * Retrieves whether this database supports using a column that is
90ce3da70b43 Initial load
duke
parents:
diff changeset
   502
     * not in the <code>SELECT</code> statement in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
   503
     * <code>GROUP BY</code> clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   504
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   505
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   506
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   507
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   508
    boolean supportsGroupByUnrelated() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   509
90ce3da70b43 Initial load
duke
parents:
diff changeset
   510
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   511
     * Retrieves whether this database supports using columns not included in
90ce3da70b43 Initial load
duke
parents:
diff changeset
   512
     * the <code>SELECT</code> statement in a <code>GROUP BY</code> clause
90ce3da70b43 Initial load
duke
parents:
diff changeset
   513
     * provided that all of the columns in the <code>SELECT</code> statement
90ce3da70b43 Initial load
duke
parents:
diff changeset
   514
     * are included in the <code>GROUP BY</code> clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   515
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   516
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   517
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   518
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   519
    boolean supportsGroupByBeyondSelect() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   520
90ce3da70b43 Initial load
duke
parents:
diff changeset
   521
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   522
     * Retrieves whether this database supports specifying a
90ce3da70b43 Initial load
duke
parents:
diff changeset
   523
     * <code>LIKE</code> escape clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   524
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   525
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   526
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   527
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   528
    boolean supportsLikeEscapeClause() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   529
90ce3da70b43 Initial load
duke
parents:
diff changeset
   530
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   531
     * Retrieves whether this database supports getting multiple
90ce3da70b43 Initial load
duke
parents:
diff changeset
   532
     * <code>ResultSet</code> objects from a single call to the
90ce3da70b43 Initial load
duke
parents:
diff changeset
   533
     * method <code>execute</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   534
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   535
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   536
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   537
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   538
    boolean supportsMultipleResultSets() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   539
90ce3da70b43 Initial load
duke
parents:
diff changeset
   540
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   541
     * Retrieves whether this database allows having multiple
90ce3da70b43 Initial load
duke
parents:
diff changeset
   542
     * transactions open at once (on different connections).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   543
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   544
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   545
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   546
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   547
    boolean supportsMultipleTransactions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   548
90ce3da70b43 Initial load
duke
parents:
diff changeset
   549
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   550
     * Retrieves whether columns in this database may be defined as non-nullable.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   551
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   552
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   553
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   554
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   555
    boolean supportsNonNullableColumns() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   556
90ce3da70b43 Initial load
duke
parents:
diff changeset
   557
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   558
     * Retrieves whether this database supports the ODBC Minimum SQL grammar.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   559
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   560
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   561
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   562
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   563
    boolean supportsMinimumSQLGrammar() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   564
90ce3da70b43 Initial load
duke
parents:
diff changeset
   565
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   566
     * Retrieves whether this database supports the ODBC Core SQL grammar.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   567
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   568
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   569
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   570
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   571
    boolean supportsCoreSQLGrammar() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   572
90ce3da70b43 Initial load
duke
parents:
diff changeset
   573
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   574
     * Retrieves whether this database supports the ODBC Extended SQL grammar.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   575
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   576
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   577
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   578
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   579
    boolean supportsExtendedSQLGrammar() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   580
90ce3da70b43 Initial load
duke
parents:
diff changeset
   581
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   582
     * Retrieves whether this database supports the ANSI92 entry level SQL
90ce3da70b43 Initial load
duke
parents:
diff changeset
   583
     * grammar.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   584
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   585
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   586
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   587
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   588
    boolean supportsANSI92EntryLevelSQL() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   589
90ce3da70b43 Initial load
duke
parents:
diff changeset
   590
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   591
     * Retrieves whether this database supports the ANSI92 intermediate SQL grammar supported.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   592
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   593
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   594
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   595
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   596
    boolean supportsANSI92IntermediateSQL() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   597
90ce3da70b43 Initial load
duke
parents:
diff changeset
   598
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   599
     * Retrieves whether this database supports the ANSI92 full SQL grammar supported.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   600
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   601
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   602
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   603
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   604
    boolean supportsANSI92FullSQL() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   605
90ce3da70b43 Initial load
duke
parents:
diff changeset
   606
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   607
     * Retrieves whether this database supports the SQL Integrity
90ce3da70b43 Initial load
duke
parents:
diff changeset
   608
     * Enhancement Facility.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   609
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   610
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   611
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   612
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   613
    boolean supportsIntegrityEnhancementFacility() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   614
90ce3da70b43 Initial load
duke
parents:
diff changeset
   615
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   616
     * Retrieves whether this database supports some form of outer join.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   617
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   618
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   619
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   620
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   621
    boolean supportsOuterJoins() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   622
90ce3da70b43 Initial load
duke
parents:
diff changeset
   623
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   624
     * Retrieves whether this database supports full nested outer joins.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   625
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   626
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   627
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   628
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   629
    boolean supportsFullOuterJoins() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   630
90ce3da70b43 Initial load
duke
parents:
diff changeset
   631
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   632
     * Retrieves whether this database provides limited support for outer
90ce3da70b43 Initial load
duke
parents:
diff changeset
   633
     * joins.  (This will be <code>true</code> if the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
   634
     * <code>supportsFullOuterJoins</code> returns <code>true</code>).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   635
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   636
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   637
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   638
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   639
    boolean supportsLimitedOuterJoins() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   640
90ce3da70b43 Initial load
duke
parents:
diff changeset
   641
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   642
     * Retrieves the database vendor's preferred term for "schema".
90ce3da70b43 Initial load
duke
parents:
diff changeset
   643
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   644
     * @return the vendor term for "schema"
90ce3da70b43 Initial load
duke
parents:
diff changeset
   645
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   646
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   647
    String getSchemaTerm() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   648
90ce3da70b43 Initial load
duke
parents:
diff changeset
   649
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   650
     * Retrieves the database vendor's preferred term for "procedure".
90ce3da70b43 Initial load
duke
parents:
diff changeset
   651
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   652
     * @return the vendor term for "procedure"
90ce3da70b43 Initial load
duke
parents:
diff changeset
   653
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   654
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   655
    String getProcedureTerm() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   656
90ce3da70b43 Initial load
duke
parents:
diff changeset
   657
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   658
     * Retrieves the database vendor's preferred term for "catalog".
90ce3da70b43 Initial load
duke
parents:
diff changeset
   659
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   660
     * @return the vendor term for "catalog"
90ce3da70b43 Initial load
duke
parents:
diff changeset
   661
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   662
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   663
    String getCatalogTerm() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   664
90ce3da70b43 Initial load
duke
parents:
diff changeset
   665
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   666
     * Retrieves whether a catalog appears at the start of a fully qualified
90ce3da70b43 Initial load
duke
parents:
diff changeset
   667
     * table name.  If not, the catalog appears at the end.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   668
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   669
     * @return <code>true</code> if the catalog name appears at the beginning
90ce3da70b43 Initial load
duke
parents:
diff changeset
   670
     *         of a fully qualified table name; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   671
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   672
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   673
    boolean isCatalogAtStart() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   674
90ce3da70b43 Initial load
duke
parents:
diff changeset
   675
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   676
     * Retrieves the <code>String</code> that this database uses as the
90ce3da70b43 Initial load
duke
parents:
diff changeset
   677
     * separator between a catalog and table name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   678
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   679
     * @return the separator string
90ce3da70b43 Initial load
duke
parents:
diff changeset
   680
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   681
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   682
    String getCatalogSeparator() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   683
90ce3da70b43 Initial load
duke
parents:
diff changeset
   684
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   685
     * Retrieves whether a schema name can be used in a data manipulation statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   686
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   687
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   688
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   689
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   690
    boolean supportsSchemasInDataManipulation() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   691
90ce3da70b43 Initial load
duke
parents:
diff changeset
   692
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   693
     * Retrieves whether a schema name can be used in a procedure call statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   694
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   695
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   696
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   697
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   698
    boolean supportsSchemasInProcedureCalls() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   699
90ce3da70b43 Initial load
duke
parents:
diff changeset
   700
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   701
     * Retrieves whether a schema name can be used in a table definition statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   702
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   703
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   704
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   705
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   706
    boolean supportsSchemasInTableDefinitions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   707
90ce3da70b43 Initial load
duke
parents:
diff changeset
   708
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   709
     * Retrieves whether a schema name can be used in an index definition statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   710
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   711
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   712
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   713
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   714
    boolean supportsSchemasInIndexDefinitions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   715
90ce3da70b43 Initial load
duke
parents:
diff changeset
   716
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   717
     * Retrieves whether a schema name can be used in a privilege definition statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   718
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   719
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   720
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   721
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   722
    boolean supportsSchemasInPrivilegeDefinitions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   723
90ce3da70b43 Initial load
duke
parents:
diff changeset
   724
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   725
     * Retrieves whether a catalog name can be used in a data manipulation statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   726
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   727
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   728
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   729
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   730
    boolean supportsCatalogsInDataManipulation() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   731
90ce3da70b43 Initial load
duke
parents:
diff changeset
   732
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   733
     * Retrieves whether a catalog name can be used in a procedure call statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   734
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   735
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   736
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   737
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   738
    boolean supportsCatalogsInProcedureCalls() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   739
90ce3da70b43 Initial load
duke
parents:
diff changeset
   740
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   741
     * Retrieves whether a catalog name can be used in a table definition statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   742
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   743
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   744
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   745
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   746
    boolean supportsCatalogsInTableDefinitions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   747
90ce3da70b43 Initial load
duke
parents:
diff changeset
   748
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   749
     * Retrieves whether a catalog name can be used in an index definition statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   750
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   751
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   752
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   753
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   754
    boolean supportsCatalogsInIndexDefinitions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   755
90ce3da70b43 Initial load
duke
parents:
diff changeset
   756
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   757
     * Retrieves whether a catalog name can be used in a privilege definition statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   758
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   759
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   760
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   761
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   762
    boolean supportsCatalogsInPrivilegeDefinitions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   763
90ce3da70b43 Initial load
duke
parents:
diff changeset
   764
90ce3da70b43 Initial load
duke
parents:
diff changeset
   765
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   766
     * Retrieves whether this database supports positioned <code>DELETE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   767
     * statements.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   768
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   769
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   770
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   771
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   772
    boolean supportsPositionedDelete() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   773
90ce3da70b43 Initial load
duke
parents:
diff changeset
   774
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   775
     * Retrieves whether this database supports positioned <code>UPDATE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   776
     * statements.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   777
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   778
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   779
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   780
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   781
    boolean supportsPositionedUpdate() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   782
90ce3da70b43 Initial load
duke
parents:
diff changeset
   783
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   784
     * Retrieves whether this database supports <code>SELECT FOR UPDATE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   785
     * statements.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   786
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   787
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   788
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   789
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   790
    boolean supportsSelectForUpdate() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   791
90ce3da70b43 Initial load
duke
parents:
diff changeset
   792
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   793
     * Retrieves whether this database supports stored procedure calls
90ce3da70b43 Initial load
duke
parents:
diff changeset
   794
     * that use the stored procedure escape syntax.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   795
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   796
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   797
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   798
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   799
    boolean supportsStoredProcedures() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   800
90ce3da70b43 Initial load
duke
parents:
diff changeset
   801
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   802
     * Retrieves whether this database supports subqueries in comparison
90ce3da70b43 Initial load
duke
parents:
diff changeset
   803
     * expressions.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   804
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   805
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   806
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   807
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   808
    boolean supportsSubqueriesInComparisons() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   809
90ce3da70b43 Initial load
duke
parents:
diff changeset
   810
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   811
     * Retrieves whether this database supports subqueries in
90ce3da70b43 Initial load
duke
parents:
diff changeset
   812
     * <code>EXISTS</code> expressions.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   813
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   814
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   815
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   816
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   817
    boolean supportsSubqueriesInExists() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   818
90ce3da70b43 Initial load
duke
parents:
diff changeset
   819
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   820
     * Retrieves whether this database supports subqueries in
90ce3da70b43 Initial load
duke
parents:
diff changeset
   821
     * <code>IN</code> expressions.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   822
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   823
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   824
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   825
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   826
    boolean supportsSubqueriesInIns() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   827
90ce3da70b43 Initial load
duke
parents:
diff changeset
   828
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   829
     * Retrieves whether this database supports subqueries in quantified
90ce3da70b43 Initial load
duke
parents:
diff changeset
   830
     * expressions.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   831
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   832
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   833
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   834
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   835
    boolean supportsSubqueriesInQuantifieds() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   836
90ce3da70b43 Initial load
duke
parents:
diff changeset
   837
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   838
     * Retrieves whether this database supports correlated subqueries.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   839
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   840
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   841
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   842
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   843
    boolean supportsCorrelatedSubqueries() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   844
90ce3da70b43 Initial load
duke
parents:
diff changeset
   845
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   846
     * Retrieves whether this database supports SQL <code>UNION</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   847
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   848
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   849
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   850
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   851
    boolean supportsUnion() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   852
90ce3da70b43 Initial load
duke
parents:
diff changeset
   853
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   854
     * Retrieves whether this database supports SQL <code>UNION ALL</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   855
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   856
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
   857
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   858
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   859
    boolean supportsUnionAll() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   860
90ce3da70b43 Initial load
duke
parents:
diff changeset
   861
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   862
     * Retrieves whether this database supports keeping cursors open
90ce3da70b43 Initial load
duke
parents:
diff changeset
   863
     * across commits.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   864
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   865
     * @return <code>true</code> if cursors always remain open;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   866
     *       <code>false</code> if they might not remain open
90ce3da70b43 Initial load
duke
parents:
diff changeset
   867
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   868
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   869
    boolean supportsOpenCursorsAcrossCommit() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   870
90ce3da70b43 Initial load
duke
parents:
diff changeset
   871
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   872
     * Retrieves whether this database supports keeping cursors open
90ce3da70b43 Initial load
duke
parents:
diff changeset
   873
     * across rollbacks.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   874
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   875
     * @return <code>true</code> if cursors always remain open;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   876
     *       <code>false</code> if they might not remain open
90ce3da70b43 Initial load
duke
parents:
diff changeset
   877
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   878
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   879
    boolean supportsOpenCursorsAcrossRollback() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   880
90ce3da70b43 Initial load
duke
parents:
diff changeset
   881
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   882
     * Retrieves whether this database supports keeping statements open
90ce3da70b43 Initial load
duke
parents:
diff changeset
   883
     * across commits.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   884
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   885
     * @return <code>true</code> if statements always remain open;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   886
     *       <code>false</code> if they might not remain open
90ce3da70b43 Initial load
duke
parents:
diff changeset
   887
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   888
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   889
    boolean supportsOpenStatementsAcrossCommit() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   890
90ce3da70b43 Initial load
duke
parents:
diff changeset
   891
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   892
     * Retrieves whether this database supports keeping statements open
90ce3da70b43 Initial load
duke
parents:
diff changeset
   893
     * across rollbacks.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   894
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   895
     * @return <code>true</code> if statements always remain open;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   896
     *       <code>false</code> if they might not remain open
90ce3da70b43 Initial load
duke
parents:
diff changeset
   897
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   898
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   899
    boolean supportsOpenStatementsAcrossRollback() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   900
90ce3da70b43 Initial load
duke
parents:
diff changeset
   901
90ce3da70b43 Initial load
duke
parents:
diff changeset
   902
90ce3da70b43 Initial load
duke
parents:
diff changeset
   903
    //----------------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   904
    // The following group of methods exposes various limitations
90ce3da70b43 Initial load
duke
parents:
diff changeset
   905
    // based on the target database with the current driver.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   906
    // Unless otherwise specified, a result of zero means there is no
90ce3da70b43 Initial load
duke
parents:
diff changeset
   907
    // limit, or the limit is not known.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   908
90ce3da70b43 Initial load
duke
parents:
diff changeset
   909
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   910
     * Retrieves the maximum number of hex characters this database allows in an
90ce3da70b43 Initial load
duke
parents:
diff changeset
   911
     * inline binary literal.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   912
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   913
     * @return max the maximum length (in hex characters) for a binary literal;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   914
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
   915
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
   916
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   917
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   918
    int getMaxBinaryLiteralLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   919
90ce3da70b43 Initial load
duke
parents:
diff changeset
   920
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   921
     * Retrieves the maximum number of characters this database allows
90ce3da70b43 Initial load
duke
parents:
diff changeset
   922
     * for a character literal.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   923
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   924
     * @return the maximum number of characters allowed for a character literal;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   925
     *      a result of zero means that there is no limit or the limit is
90ce3da70b43 Initial load
duke
parents:
diff changeset
   926
     *      not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
   927
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   928
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   929
    int getMaxCharLiteralLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   930
90ce3da70b43 Initial load
duke
parents:
diff changeset
   931
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   932
     * Retrieves the maximum number of characters this database allows
90ce3da70b43 Initial load
duke
parents:
diff changeset
   933
     * for a column name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   934
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   935
     * @return the maximum number of characters allowed for a column name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   936
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
   937
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
   938
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   939
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   940
    int getMaxColumnNameLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   941
90ce3da70b43 Initial load
duke
parents:
diff changeset
   942
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   943
     * Retrieves the maximum number of columns this database allows in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
   944
     * <code>GROUP BY</code> clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   945
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   946
     * @return the maximum number of columns allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   947
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
   948
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
   949
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   950
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   951
    int getMaxColumnsInGroupBy() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   952
90ce3da70b43 Initial load
duke
parents:
diff changeset
   953
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   954
     * Retrieves the maximum number of columns this database allows in an index.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   955
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   956
     * @return the maximum number of columns allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   957
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
   958
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
   959
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   960
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   961
    int getMaxColumnsInIndex() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   962
90ce3da70b43 Initial load
duke
parents:
diff changeset
   963
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   964
     * Retrieves the maximum number of columns this database allows in an
90ce3da70b43 Initial load
duke
parents:
diff changeset
   965
     * <code>ORDER BY</code> clause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   966
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   967
     * @return the maximum number of columns allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   968
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
   969
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
   970
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   971
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   972
    int getMaxColumnsInOrderBy() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   973
90ce3da70b43 Initial load
duke
parents:
diff changeset
   974
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   975
     * Retrieves the maximum number of columns this database allows in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
   976
     * <code>SELECT</code> list.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   977
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   978
     * @return the maximum number of columns allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   979
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
   980
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
   981
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   982
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   983
    int getMaxColumnsInSelect() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   984
90ce3da70b43 Initial load
duke
parents:
diff changeset
   985
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   986
     * Retrieves the maximum number of columns this database allows in a table.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   987
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   988
     * @return the maximum number of columns allowed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   989
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
   990
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
   991
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   992
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   993
    int getMaxColumnsInTable() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   994
90ce3da70b43 Initial load
duke
parents:
diff changeset
   995
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   996
     * Retrieves the maximum number of concurrent connections to this
90ce3da70b43 Initial load
duke
parents:
diff changeset
   997
     * database that are possible.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   998
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   999
     * @return the maximum number of active connections possible at one time;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1000
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1001
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1002
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1003
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1004
    int getMaxConnections() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1005
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1006
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1007
     * Retrieves the maximum number of characters that this database allows in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1008
     * cursor name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1009
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1010
     * @return the maximum number of characters allowed in a cursor name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1011
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1012
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1013
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1014
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1015
    int getMaxCursorNameLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1016
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1017
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1018
     * Retrieves the maximum number of bytes this database allows for an
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1019
     * index, including all of the parts of the index.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1020
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1021
     * @return the maximum number of bytes allowed; this limit includes the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1022
     *      composite of all the constituent parts of the index;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1023
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1024
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1025
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1026
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1027
    int getMaxIndexLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1028
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1029
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1030
     * Retrieves the maximum number of characters that this database allows in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1031
     * schema name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1032
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1033
     * @return the maximum number of characters allowed in a schema name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1034
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1035
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1036
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1037
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1038
    int getMaxSchemaNameLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1039
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1040
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1041
     * Retrieves the maximum number of characters that this database allows in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1042
     * procedure name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1043
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1044
     * @return the maximum number of characters allowed in a procedure name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1045
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1046
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1047
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1048
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1049
    int getMaxProcedureNameLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1050
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1051
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1052
     * Retrieves the maximum number of characters that this database allows in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1053
     * catalog name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1054
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1055
     * @return the maximum number of characters allowed in a catalog name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1056
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1057
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1058
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1059
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1060
    int getMaxCatalogNameLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1061
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1062
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1063
     * Retrieves the maximum number of bytes this database allows in
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1064
     * a single row.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1065
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1066
     * @return the maximum number of bytes allowed for a row; a result of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1067
     *         zero means that there is no limit or the limit is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1068
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1069
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1070
    int getMaxRowSize() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1071
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1072
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1073
     * Retrieves whether the return value for the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1074
     * <code>getMaxRowSize</code> includes the SQL data types
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1075
     * <code>LONGVARCHAR</code> and <code>LONGVARBINARY</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1076
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1077
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1078
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1079
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1080
    boolean doesMaxRowSizeIncludeBlobs() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1081
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1082
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1083
     * Retrieves the maximum number of characters this database allows in
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1084
     * an SQL statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1085
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1086
     * @return the maximum number of characters allowed for an SQL statement;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1087
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1088
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1089
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1090
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1091
    int getMaxStatementLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1092
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1093
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1094
     * Retrieves the maximum number of active statements to this database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1095
     * that can be open at the same time.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1096
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1097
     * @return the maximum number of statements that can be open at one time;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1098
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1099
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1100
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1101
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1102
    int getMaxStatements() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1103
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1104
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1105
     * Retrieves the maximum number of characters this database allows in
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1106
     * a table name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1107
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1108
     * @return the maximum number of characters allowed for a table name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1109
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1110
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1111
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1112
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1113
    int getMaxTableNameLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1114
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1115
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1116
     * Retrieves the maximum number of tables this database allows in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1117
     * <code>SELECT</code> statement.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1118
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1119
     * @return the maximum number of tables allowed in a <code>SELECT</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1120
     *         statement; a result of zero means that there is no limit or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1121
     *         the limit is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1122
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1123
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1124
    int getMaxTablesInSelect() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1125
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1126
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1127
     * Retrieves the maximum number of characters this database allows in
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1128
     * a user name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1129
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1130
     * @return the maximum number of characters allowed for a user name;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1131
     *      a result of zero means that there is no limit or the limit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1132
     *      is not known
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1133
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1134
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1135
    int getMaxUserNameLength() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1136
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1137
    //----------------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1138
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1139
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1140
     * Retrieves this database's default transaction isolation level.  The
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1141
     * possible values are defined in <code>java.sql.Connection</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1142
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1143
     * @return the default isolation level
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1144
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1145
     * @see Connection
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1146
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1147
    int getDefaultTransactionIsolation() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1148
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1149
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1150
     * Retrieves whether this database supports transactions. If not, invoking the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1151
     * method <code>commit</code> is a noop, and the isolation level is
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1152
     * <code>TRANSACTION_NONE</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1153
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1154
     * @return <code>true</code> if transactions are supported;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1155
     *         <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1156
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1157
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1158
    boolean supportsTransactions() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1159
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1160
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1161
     * Retrieves whether this database supports the given transaction isolation level.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1162
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1163
     * @param level one of the transaction isolation levels defined in
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1164
     *         <code>java.sql.Connection</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1165
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1166
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1167
     * @see Connection
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1168
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1169
    boolean supportsTransactionIsolationLevel(int level)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1170
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1171
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1172
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1173
     * Retrieves whether this database supports both data definition and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1174
     * data manipulation statements within a transaction.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1175
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1176
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1177
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1178
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1179
    boolean supportsDataDefinitionAndDataManipulationTransactions()
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1180
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1181
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1182
     * Retrieves whether this database supports only data manipulation
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1183
     * statements within a transaction.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1184
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1185
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1186
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1187
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1188
    boolean supportsDataManipulationTransactionsOnly()
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1189
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1190
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1191
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1192
     * Retrieves whether a data definition statement within a transaction forces
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1193
     * the transaction to commit.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1194
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1195
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1196
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1197
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1198
    boolean dataDefinitionCausesTransactionCommit()
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1199
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1200
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1201
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1202
     * Retrieves whether this database ignores a data definition statement
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1203
     * within a transaction.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1204
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1205
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1206
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1207
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1208
    boolean dataDefinitionIgnoredInTransactions()
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1209
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1210
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1211
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1212
     * Retrieves a description of the stored procedures available in the given
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1213
     * catalog.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1214
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1215
     * Only procedure descriptions matching the schema and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1216
     * procedure name criteria are returned.  They are ordered by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1217
     * <code>PROCEDURE_CAT</code>, <code>PROCEDURE_SCHEM</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1218
     * <code>PROCEDURE_NAME</code> and <code>SPECIFIC_ NAME</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1219
     *
25976
4de01a56e3ee 8054555: javadoc cleanup for java.sql and javax.sql
lancea
parents: 23590
diff changeset
  1220
     * <P>Each procedure description has the following columns:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1221
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1222
     *  <LI><B>PROCEDURE_CAT</B> String {@code =>} procedure catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1223
     *  <LI><B>PROCEDURE_SCHEM</B> String {@code =>} procedure schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1224
     *  <LI><B>PROCEDURE_NAME</B> String {@code =>} procedure name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1225
     *  <LI> reserved for future use
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1226
     *  <LI> reserved for future use
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1227
     *  <LI> reserved for future use
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1228
     *  <LI><B>REMARKS</B> String {@code =>} explanatory comment on the procedure
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1229
     *  <LI><B>PROCEDURE_TYPE</B> short {@code =>} kind of procedure:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1230
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1231
     *      <LI> procedureResultUnknown - Cannot determine if  a return value
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1232
     *       will be returned
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1233
     *      <LI> procedureNoResult - Does not return a return value
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1234
     *      <LI> procedureReturnsResult - Returns a return value
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1235
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1236
     *  <LI><B>SPECIFIC_NAME</B> String  {@code =>} The name which uniquely identifies this
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1237
     * procedure within its schema.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1238
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1239
     * <p>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1240
     * A user may not have permissions to execute any of the procedures that are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1241
     * returned by <code>getProcedures</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1242
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1243
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1244
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1245
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1246
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1247
     * @param schemaPattern a schema name pattern; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1248
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1249
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1250
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1251
     * @param procedureNamePattern a procedure name pattern; must match the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1252
     *        procedure name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1253
     * @return <code>ResultSet</code> - each row is a procedure description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1254
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1255
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1256
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1257
    ResultSet getProcedures(String catalog, String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1258
                            String procedureNamePattern) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1259
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1260
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1261
     * Indicates that it is not known whether the procedure returns
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1262
     * a result.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1263
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1264
     * A possible value for column <code>PROCEDURE_TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1265
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1266
     * <code>getProcedures</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1267
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1268
    int procedureResultUnknown  = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1269
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1270
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1271
     * Indicates that the procedure does not return a result.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1272
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1273
     * A possible value for column <code>PROCEDURE_TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1274
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1275
     * <code>getProcedures</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1276
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1277
    int procedureNoResult               = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1278
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1279
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1280
     * Indicates that the procedure returns a result.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1281
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1282
     * A possible value for column <code>PROCEDURE_TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1283
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1284
     * <code>getProcedures</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1285
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1286
    int procedureReturnsResult  = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1287
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1288
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1289
     * Retrieves a description of the given catalog's stored procedure parameter
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1290
     * and result columns.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1291
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1292
     * <P>Only descriptions matching the schema, procedure and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1293
     * parameter name criteria are returned.  They are ordered by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1294
     * PROCEDURE_CAT, PROCEDURE_SCHEM, PROCEDURE_NAME and SPECIFIC_NAME. Within this, the return value,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1295
     * if any, is first. Next are the parameter descriptions in call
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1296
     * order. The column descriptions follow in column number order.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1297
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1298
     * <P>Each row in the <code>ResultSet</code> is a parameter description or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1299
     * column description with the following fields:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1300
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1301
     *  <LI><B>PROCEDURE_CAT</B> String {@code =>} procedure catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1302
     *  <LI><B>PROCEDURE_SCHEM</B> String {@code =>} procedure schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1303
     *  <LI><B>PROCEDURE_NAME</B> String {@code =>} procedure name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1304
     *  <LI><B>COLUMN_NAME</B> String {@code =>} column/parameter name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1305
     *  <LI><B>COLUMN_TYPE</B> Short {@code =>} kind of column/parameter:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1306
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1307
     *      <LI> procedureColumnUnknown - nobody knows
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1308
     *      <LI> procedureColumnIn - IN parameter
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1309
     *      <LI> procedureColumnInOut - INOUT parameter
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1310
     *      <LI> procedureColumnOut - OUT parameter
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1311
     *      <LI> procedureColumnReturn - procedure return value
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1312
     *      <LI> procedureColumnResult - result column in <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1313
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1314
     *  <LI><B>DATA_TYPE</B> int {@code =>} SQL type from java.sql.Types
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1315
     *  <LI><B>TYPE_NAME</B> String {@code =>} SQL type name, for a UDT type the
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1316
     *  type name is fully qualified
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1317
     *  <LI><B>PRECISION</B> int {@code =>} precision
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1318
     *  <LI><B>LENGTH</B> int {@code =>} length in bytes of data
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1319
     *  <LI><B>SCALE</B> short {@code =>} scale -  null is returned for data types where
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1320
     * SCALE is not applicable.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1321
     *  <LI><B>RADIX</B> short {@code =>} radix
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1322
     *  <LI><B>NULLABLE</B> short {@code =>} can it contain NULL.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1323
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1324
     *      <LI> procedureNoNulls - does not allow NULL values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1325
     *      <LI> procedureNullable - allows NULL values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1326
     *      <LI> procedureNullableUnknown - nullability unknown
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1327
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1328
     *  <LI><B>REMARKS</B> String {@code =>} comment describing parameter/column
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1329
     *  <LI><B>COLUMN_DEF</B> String {@code =>} default value for the column, which should be interpreted as a string when the value is enclosed in single quotes (may be <code>null</code>)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1330
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1331
     *      <LI> The string NULL (not enclosed in quotes) - if NULL was specified as the default value
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1332
     *      <LI> TRUNCATE (not enclosed in quotes)        - if the specified default value cannot be represented without truncation
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1333
     *      <LI> NULL                                     - if a default value was not specified
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1334
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1335
     *  <LI><B>SQL_DATA_TYPE</B> int  {@code =>} reserved for future use
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1336
     *  <LI><B>SQL_DATETIME_SUB</B> int  {@code =>} reserved for future use
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1337
     *  <LI><B>CHAR_OCTET_LENGTH</B> int  {@code =>} the maximum length of binary and character based columns.  For any other datatype the returned value is a
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1338
     * NULL
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1339
     *  <LI><B>ORDINAL_POSITION</B> int  {@code =>} the ordinal position, starting from 1, for the input and output parameters for a procedure. A value of 0
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1340
     *is returned if this row describes the procedure's return value.  For result set columns, it is the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1341
     *ordinal position of the column in the result set starting from 1.  If there are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1342
     *multiple result sets, the column ordinal positions are implementation
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1343
     * defined.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1344
     *  <LI><B>IS_NULLABLE</B> String  {@code =>} ISO rules are used to determine the nullability for a column.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1345
     *       <UL>
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1346
     *       <LI> YES           --- if the column can include NULLs
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1347
     *       <LI> NO            --- if the column cannot include NULLs
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1348
     *       <LI> empty string  --- if the nullability for the
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1349
     * column is unknown
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1350
     *       </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1351
     *  <LI><B>SPECIFIC_NAME</B> String  {@code =>} the name which uniquely identifies this procedure within its schema.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1352
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1353
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1354
     * <P><B>Note:</B> Some databases may not return the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1355
     * descriptions for a procedure.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1356
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1357
     * <p>The PRECISION column represents the specified column size for the given column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1358
     * For numeric data, this is the maximum precision.  For character data, this is the length in characters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1359
     * For datetime datatypes, this is the length in characters of the String representation (assuming the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1360
     * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1361
     * this is the length in bytes. Null is returned for data types where the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1362
     * column size is not applicable.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1363
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1364
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1365
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1366
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1367
     * @param schemaPattern a schema name pattern; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1368
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1369
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1370
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1371
     * @param procedureNamePattern a procedure name pattern; must match the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1372
     *        procedure name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1373
     * @param columnNamePattern a column name pattern; must match the column name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1374
     *        as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1375
     * @return <code>ResultSet</code> - each row describes a stored procedure parameter or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1376
     *      column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1377
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1378
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1379
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1380
    ResultSet getProcedureColumns(String catalog,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1381
                                  String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1382
                                  String procedureNamePattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1383
                                  String columnNamePattern) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1384
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1385
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1386
     * Indicates that type of the column is unknown.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1387
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1388
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1389
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1390
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1391
     * returned by the method <code>getProcedureColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1392
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1393
    int procedureColumnUnknown = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1394
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1395
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1396
     * Indicates that the column stores IN parameters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1397
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1398
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1399
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1400
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1401
     * returned by the method <code>getProcedureColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1402
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1403
    int procedureColumnIn = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1404
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1405
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1406
     * Indicates that the column stores INOUT parameters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1407
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1408
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1409
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1410
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1411
     * returned by the method <code>getProcedureColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1412
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1413
    int procedureColumnInOut = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1414
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1415
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1416
     * Indicates that the column stores OUT parameters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1417
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1418
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1419
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1420
     * in the <code>ResultSet</code>
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  1421
     * returned by the method <code>getProcedureColumns</code>.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1422
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1423
    int procedureColumnOut = 4;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1424
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1425
     * Indicates that the column stores return values.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1426
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1427
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1428
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1429
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1430
     * returned by the method <code>getProcedureColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1431
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1432
    int procedureColumnReturn = 5;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1433
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1434
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1435
     * Indicates that the column stores results.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1436
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1437
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1438
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1439
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1440
     * returned by the method <code>getProcedureColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1441
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1442
    int procedureColumnResult = 3;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1443
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1444
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1445
     * Indicates that <code>NULL</code> values are not allowed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1446
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1447
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1448
     * <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1449
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1450
     * returned by the method <code>getProcedureColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1451
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1452
    int procedureNoNulls = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1453
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1454
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1455
     * Indicates that <code>NULL</code> values are allowed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1456
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1457
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1458
     * <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1459
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1460
     * returned by the method <code>getProcedureColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1461
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1462
    int procedureNullable = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1463
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1464
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1465
     * Indicates that whether <code>NULL</code> values are allowed
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1466
     * is unknown.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1467
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1468
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1469
     * <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1470
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1471
     * returned by the method <code>getProcedureColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1472
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1473
    int procedureNullableUnknown = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1474
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1475
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1476
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1477
     * Retrieves a description of the tables available in the given catalog.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1478
     * Only table descriptions matching the catalog, schema, table
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1479
     * name and type criteria are returned.  They are ordered by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1480
     * <code>TABLE_TYPE</code>, <code>TABLE_CAT</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1481
     * <code>TABLE_SCHEM</code> and <code>TABLE_NAME</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1482
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1483
     * Each table description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1484
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1485
     *  <LI><B>TABLE_CAT</B> String {@code =>} table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1486
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1487
     *  <LI><B>TABLE_NAME</B> String {@code =>} table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1488
     *  <LI><B>TABLE_TYPE</B> String {@code =>} table type.  Typical types are "TABLE",
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1489
     *                  "VIEW", "SYSTEM TABLE", "GLOBAL TEMPORARY",
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1490
     *                  "LOCAL TEMPORARY", "ALIAS", "SYNONYM".
25976
4de01a56e3ee 8054555: javadoc cleanup for java.sql and javax.sql
lancea
parents: 23590
diff changeset
  1491
     *  <LI><B>REMARKS</B> String {@code =>} explanatory comment on the table (may be {@code null})
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1492
     *  <LI><B>TYPE_CAT</B> String {@code =>} the types catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1493
     *  <LI><B>TYPE_SCHEM</B> String {@code =>} the types schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1494
     *  <LI><B>TYPE_NAME</B> String {@code =>} type name (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1495
     *  <LI><B>SELF_REFERENCING_COL_NAME</B> String {@code =>} name of the designated
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1496
     *                  "identifier" column of a typed table (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1497
     *  <LI><B>REF_GENERATION</B> String {@code =>} specifies how values in
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1498
     *                  SELF_REFERENCING_COL_NAME are created. Values are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1499
     *                  "SYSTEM", "USER", "DERIVED". (may be <code>null</code>)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1500
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1501
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1502
     * <P><B>Note:</B> Some databases may not return information for
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1503
     * all tables.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1504
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1505
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1506
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1507
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1508
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1509
     * @param schemaPattern a schema name pattern; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1510
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1511
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1512
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1513
     * @param tableNamePattern a table name pattern; must match the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1514
     *        table name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1515
     * @param types a list of table types, which must be from the list of table types
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1516
     *         returned from {@link #getTableTypes},to include; <code>null</code> returns
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1517
     * all types
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1518
     * @return <code>ResultSet</code> - each row is a table description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1519
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1520
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1521
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1522
    ResultSet getTables(String catalog, String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1523
                        String tableNamePattern, String types[]) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1524
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1525
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1526
     * Retrieves the schema names available in this database.  The results
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1527
     * are ordered by <code>TABLE_CATALOG</code> and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1528
     * <code>TABLE_SCHEM</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1529
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1530
     * <P>The schema columns are:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1531
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1532
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} schema name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1533
     *  <LI><B>TABLE_CATALOG</B> String {@code =>} catalog name (may be <code>null</code>)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1534
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1535
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1536
     * @return a <code>ResultSet</code> object in which each row is a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1537
     *         schema description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1538
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1539
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1540
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1541
    ResultSet getSchemas() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1542
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1543
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1544
     * Retrieves the catalog names available in this database.  The results
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1545
     * are ordered by catalog name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1546
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1547
     * <P>The catalog column is:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1548
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1549
     *  <LI><B>TABLE_CAT</B> String {@code =>} catalog name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1550
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1551
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1552
     * @return a <code>ResultSet</code> object in which each row has a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1553
     *         single <code>String</code> column that is a catalog name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1554
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1555
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1556
    ResultSet getCatalogs() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1557
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1558
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1559
     * Retrieves the table types available in this database.  The results
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1560
     * are ordered by table type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1561
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1562
     * <P>The table type is:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1563
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1564
     *  <LI><B>TABLE_TYPE</B> String {@code =>} table type.  Typical types are "TABLE",
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1565
     *                  "VIEW", "SYSTEM TABLE", "GLOBAL TEMPORARY",
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1566
     *                  "LOCAL TEMPORARY", "ALIAS", "SYNONYM".
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1567
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1568
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1569
     * @return a <code>ResultSet</code> object in which each row has a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1570
     *         single <code>String</code> column that is a table type
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1571
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1572
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1573
    ResultSet getTableTypes() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1574
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1575
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1576
     * Retrieves a description of table columns available in
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1577
     * the specified catalog.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1578
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1579
     * <P>Only column descriptions matching the catalog, schema, table
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1580
     * and column name criteria are returned.  They are ordered by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1581
     * <code>TABLE_CAT</code>,<code>TABLE_SCHEM</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1582
     * <code>TABLE_NAME</code>, and <code>ORDINAL_POSITION</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1583
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1584
     * <P>Each column description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1585
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1586
     *  <LI><B>TABLE_CAT</B> String {@code =>} table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1587
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1588
     *  <LI><B>TABLE_NAME</B> String {@code =>} table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1589
     *  <LI><B>COLUMN_NAME</B> String {@code =>} column name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1590
     *  <LI><B>DATA_TYPE</B> int {@code =>} SQL type from java.sql.Types
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1591
     *  <LI><B>TYPE_NAME</B> String {@code =>} Data source dependent type name,
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1592
     *  for a UDT the type name is fully qualified
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1593
     *  <LI><B>COLUMN_SIZE</B> int {@code =>} column size.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1594
     *  <LI><B>BUFFER_LENGTH</B> is not used.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1595
     *  <LI><B>DECIMAL_DIGITS</B> int {@code =>} the number of fractional digits. Null is returned for data types where
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1596
     * DECIMAL_DIGITS is not applicable.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1597
     *  <LI><B>NUM_PREC_RADIX</B> int {@code =>} Radix (typically either 10 or 2)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1598
     *  <LI><B>NULLABLE</B> int {@code =>} is NULL allowed.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1599
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1600
     *      <LI> columnNoNulls - might not allow <code>NULL</code> values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1601
     *      <LI> columnNullable - definitely allows <code>NULL</code> values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1602
     *      <LI> columnNullableUnknown - nullability unknown
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1603
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1604
     *  <LI><B>REMARKS</B> String {@code =>} comment describing column (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1605
     *  <LI><B>COLUMN_DEF</B> String {@code =>} default value for the column, which should be interpreted as a string when the value is enclosed in single quotes (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1606
     *  <LI><B>SQL_DATA_TYPE</B> int {@code =>} unused
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1607
     *  <LI><B>SQL_DATETIME_SUB</B> int {@code =>} unused
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1608
     *  <LI><B>CHAR_OCTET_LENGTH</B> int {@code =>} for char types the
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1609
     *       maximum number of bytes in the column
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1610
     *  <LI><B>ORDINAL_POSITION</B> int {@code =>} index of column in table
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1611
     *      (starting at 1)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1612
     *  <LI><B>IS_NULLABLE</B> String  {@code =>} ISO rules are used to determine the nullability for a column.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1613
     *       <UL>
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1614
     *       <LI> YES           --- if the column can include NULLs
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1615
     *       <LI> NO            --- if the column cannot include NULLs
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1616
     *       <LI> empty string  --- if the nullability for the
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1617
     * column is unknown
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1618
     *       </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1619
     *  <LI><B>SCOPE_CATALOG</B> String {@code =>} catalog of table that is the scope
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1620
     *      of a reference attribute (<code>null</code> if DATA_TYPE isn't REF)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1621
     *  <LI><B>SCOPE_SCHEMA</B> String {@code =>} schema of table that is the scope
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1622
     *      of a reference attribute (<code>null</code> if the DATA_TYPE isn't REF)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1623
     *  <LI><B>SCOPE_TABLE</B> String {@code =>} table name that this the scope
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1624
     *      of a reference attribute (<code>null</code> if the DATA_TYPE isn't REF)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1625
     *  <LI><B>SOURCE_DATA_TYPE</B> short {@code =>} source type of a distinct type or user-generated
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1626
     *      Ref type, SQL type from java.sql.Types (<code>null</code> if DATA_TYPE
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1627
     *      isn't DISTINCT or user-generated REF)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1628
     *   <LI><B>IS_AUTOINCREMENT</B> String  {@code =>} Indicates whether this column is auto incremented
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1629
     *       <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1630
     *       <LI> YES           --- if the column is auto incremented
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1631
     *       <LI> NO            --- if the column is not auto incremented
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1632
     *       <LI> empty string  --- if it cannot be determined whether the column is auto incremented
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1633
     *       </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1634
     *   <LI><B>IS_GENERATEDCOLUMN</B> String  {@code =>} Indicates whether this is a generated column
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1635
     *       <UL>
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1636
     *       <LI> YES           --- if this a generated column
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1637
     *       <LI> NO            --- if this not a generated column
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1638
     *       <LI> empty string  --- if it cannot be determined whether this is a generated column
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1639
     *       </UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1640
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1641
     *
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  1642
     * <p>The COLUMN_SIZE column specifies the column size for the given column.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1643
     * For numeric data, this is the maximum precision.  For character data, this is the length in characters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1644
     * For datetime datatypes, this is the length in characters of the String representation (assuming the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1645
     * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1646
     * this is the length in bytes. Null is returned for data types where the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1647
     * column size is not applicable.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1648
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1649
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1650
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1651
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1652
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1653
     * @param schemaPattern a schema name pattern; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1654
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1655
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1656
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1657
     * @param tableNamePattern a table name pattern; must match the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1658
     *        table name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1659
     * @param columnNamePattern a column name pattern; must match the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1660
     *        name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1661
     * @return <code>ResultSet</code> - each row is a column description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1662
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1663
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1664
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1665
    ResultSet getColumns(String catalog, String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1666
                         String tableNamePattern, String columnNamePattern)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1667
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1668
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1669
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1670
     * Indicates that the column might not allow <code>NULL</code> values.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1671
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1672
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1673
     * <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1674
     * in the <code>ResultSet</code> returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1675
     * <code>getColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1676
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1677
    int columnNoNulls = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1678
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1679
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1680
     * Indicates that the column definitely allows <code>NULL</code> values.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1681
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1682
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1683
     * <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1684
     * in the <code>ResultSet</code> returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1685
     * <code>getColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1686
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1687
    int columnNullable = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1688
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1689
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1690
     * Indicates that the nullability of columns is unknown.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1691
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1692
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1693
     * <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1694
     * in the <code>ResultSet</code> returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1695
     * <code>getColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1696
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1697
    int columnNullableUnknown = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1698
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1699
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1700
     * Retrieves a description of the access rights for a table's columns.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1701
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1702
     * <P>Only privileges matching the column name criteria are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1703
     * returned.  They are ordered by COLUMN_NAME and PRIVILEGE.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1704
     *
21278
ef8a3a2a72f2 8022746: List of spelling errors in API doc
malenkov
parents: 20880
diff changeset
  1705
     * <P>Each privilege description has the following columns:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1706
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1707
     *  <LI><B>TABLE_CAT</B> String {@code =>} table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1708
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1709
     *  <LI><B>TABLE_NAME</B> String {@code =>} table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1710
     *  <LI><B>COLUMN_NAME</B> String {@code =>} column name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1711
     *  <LI><B>GRANTOR</B> String {@code =>} grantor of access (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1712
     *  <LI><B>GRANTEE</B> String {@code =>} grantee of access
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1713
     *  <LI><B>PRIVILEGE</B> String {@code =>} name of access (SELECT,
25976
4de01a56e3ee 8054555: javadoc cleanup for java.sql and javax.sql
lancea
parents: 23590
diff changeset
  1714
     *      INSERT, UPDATE, REFERENCES, ...)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1715
     *  <LI><B>IS_GRANTABLE</B> String {@code =>} "YES" if grantee is permitted
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1716
     *      to grant to others; "NO" if not; <code>null</code> if unknown
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1717
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1718
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1719
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1720
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1721
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1722
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1723
     * @param schema a schema name; must match the schema name as it is
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1724
     *        stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1725
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1726
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1727
     * @param table a table name; must match the table name as it is
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1728
     *        stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1729
     * @param columnNamePattern a column name pattern; must match the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1730
     *        name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1731
     * @return <code>ResultSet</code> - each row is a column privilege description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1732
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1733
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1734
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1735
    ResultSet getColumnPrivileges(String catalog, String schema,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1736
                                  String table, String columnNamePattern) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1737
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1738
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1739
     * Retrieves a description of the access rights for each table available
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1740
     * in a catalog. Note that a table privilege applies to one or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1741
     * more columns in the table. It would be wrong to assume that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1742
     * this privilege applies to all columns (this may be true for
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1743
     * some systems but is not true for all.)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1744
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1745
     * <P>Only privileges matching the schema and table name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1746
     * criteria are returned.  They are ordered by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1747
     * <code>TABLE_CAT</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1748
     * <code>TABLE_SCHEM</code>, <code>TABLE_NAME</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1749
     * and <code>PRIVILEGE</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1750
     *
21278
ef8a3a2a72f2 8022746: List of spelling errors in API doc
malenkov
parents: 20880
diff changeset
  1751
     * <P>Each privilege description has the following columns:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1752
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1753
     *  <LI><B>TABLE_CAT</B> String {@code =>} table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1754
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1755
     *  <LI><B>TABLE_NAME</B> String {@code =>} table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1756
     *  <LI><B>GRANTOR</B> String {@code =>} grantor of access (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1757
     *  <LI><B>GRANTEE</B> String {@code =>} grantee of access
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1758
     *  <LI><B>PRIVILEGE</B> String {@code =>} name of access (SELECT,
25976
4de01a56e3ee 8054555: javadoc cleanup for java.sql and javax.sql
lancea
parents: 23590
diff changeset
  1759
     *      INSERT, UPDATE, REFERENCES, ...)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1760
     *  <LI><B>IS_GRANTABLE</B> String {@code =>} "YES" if grantee is permitted
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1761
     *      to grant to others; "NO" if not; <code>null</code> if unknown
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1762
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1763
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1764
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1765
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1766
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1767
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1768
     * @param schemaPattern a schema name pattern; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1769
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1770
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1771
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1772
     * @param tableNamePattern a table name pattern; must match the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1773
     *        table name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1774
     * @return <code>ResultSet</code> - each row is a table privilege description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1775
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1776
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1777
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1778
    ResultSet getTablePrivileges(String catalog, String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1779
                                 String tableNamePattern) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1780
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1781
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1782
     * Retrieves a description of a table's optimal set of columns that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1783
     * uniquely identifies a row. They are ordered by SCOPE.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1784
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1785
     * <P>Each column description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1786
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1787
     *  <LI><B>SCOPE</B> short {@code =>} actual scope of result
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1788
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1789
     *      <LI> bestRowTemporary - very temporary, while using row
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1790
     *      <LI> bestRowTransaction - valid for remainder of current transaction
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1791
     *      <LI> bestRowSession - valid for remainder of current session
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1792
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1793
     *  <LI><B>COLUMN_NAME</B> String {@code =>} column name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1794
     *  <LI><B>DATA_TYPE</B> int {@code =>} SQL data type from java.sql.Types
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1795
     *  <LI><B>TYPE_NAME</B> String {@code =>} Data source dependent type name,
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1796
     *  for a UDT the type name is fully qualified
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1797
     *  <LI><B>COLUMN_SIZE</B> int {@code =>} precision
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1798
     *  <LI><B>BUFFER_LENGTH</B> int {@code =>} not used
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1799
     *  <LI><B>DECIMAL_DIGITS</B> short  {@code =>} scale - Null is returned for data types where
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1800
     * DECIMAL_DIGITS is not applicable.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1801
     *  <LI><B>PSEUDO_COLUMN</B> short {@code =>} is this a pseudo column
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1802
     *      like an Oracle ROWID
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1803
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1804
     *      <LI> bestRowUnknown - may or may not be pseudo column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1805
     *      <LI> bestRowNotPseudo - is NOT a pseudo column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1806
     *      <LI> bestRowPseudo - is a pseudo column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1807
     *      </UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1808
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1809
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1810
     * <p>The COLUMN_SIZE column represents the specified column size for the given column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1811
     * For numeric data, this is the maximum precision.  For character data, this is the length in characters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1812
     * For datetime datatypes, this is the length in characters of the String representation (assuming the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1813
     * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1814
     * this is the length in bytes. Null is returned for data types where the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1815
     * column size is not applicable.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1816
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1817
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1818
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1819
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1820
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1821
     * @param schema a schema name; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1822
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1823
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1824
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1825
     * @param table a table name; must match the table name as it is stored
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1826
     *        in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1827
     * @param scope the scope of interest; use same values as SCOPE
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1828
     * @param nullable include columns that are nullable.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1829
     * @return <code>ResultSet</code> - each row is a column description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1830
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1831
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1832
    ResultSet getBestRowIdentifier(String catalog, String schema,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1833
                                   String table, int scope, boolean nullable) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1834
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1835
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1836
     * Indicates that the scope of the best row identifier is
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1837
     * very temporary, lasting only while the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1838
     * row is being used.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1839
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1840
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1841
     * <code>SCOPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1842
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1843
     * returned by the method <code>getBestRowIdentifier</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1844
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1845
    int bestRowTemporary   = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1846
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1847
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1848
     * Indicates that the scope of the best row identifier is
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1849
     * the remainder of the current transaction.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1850
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1851
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1852
     * <code>SCOPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1853
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1854
     * returned by the method <code>getBestRowIdentifier</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1855
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1856
    int bestRowTransaction = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1857
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1858
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1859
     * Indicates that the scope of the best row identifier is
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1860
     * the remainder of the current session.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1861
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1862
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1863
     * <code>SCOPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1864
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1865
     * returned by the method <code>getBestRowIdentifier</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1866
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1867
    int bestRowSession     = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1868
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1869
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1870
     * Indicates that the best row identifier may or may not be a pseudo column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1871
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1872
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1873
     * <code>PSEUDO_COLUMN</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1874
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1875
     * returned by the method <code>getBestRowIdentifier</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1876
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1877
    int bestRowUnknown  = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1878
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1879
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1880
     * Indicates that the best row identifier is NOT a pseudo column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1881
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1882
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1883
     * <code>PSEUDO_COLUMN</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1884
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1885
     * returned by the method <code>getBestRowIdentifier</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1886
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1887
    int bestRowNotPseudo        = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1888
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1889
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1890
     * Indicates that the best row identifier is a pseudo column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1891
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1892
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1893
     * <code>PSEUDO_COLUMN</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1894
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1895
     * returned by the method <code>getBestRowIdentifier</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1896
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1897
    int bestRowPseudo   = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1898
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1899
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1900
     * Retrieves a description of a table's columns that are automatically
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1901
     * updated when any value in a row is updated.  They are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1902
     * unordered.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1903
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1904
     * <P>Each column description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1905
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1906
     *  <LI><B>SCOPE</B> short {@code =>} is not used
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1907
     *  <LI><B>COLUMN_NAME</B> String {@code =>} column name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1908
     *  <LI><B>DATA_TYPE</B> int {@code =>} SQL data type from <code>java.sql.Types</code>
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1909
     *  <LI><B>TYPE_NAME</B> String {@code =>} Data source-dependent type name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1910
     *  <LI><B>COLUMN_SIZE</B> int {@code =>} precision
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1911
     *  <LI><B>BUFFER_LENGTH</B> int {@code =>} length of column value in bytes
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1912
     *  <LI><B>DECIMAL_DIGITS</B> short  {@code =>} scale - Null is returned for data types where
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1913
     * DECIMAL_DIGITS is not applicable.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1914
     *  <LI><B>PSEUDO_COLUMN</B> short {@code =>} whether this is pseudo column
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1915
     *      like an Oracle ROWID
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1916
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1917
     *      <LI> versionColumnUnknown - may or may not be pseudo column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1918
     *      <LI> versionColumnNotPseudo - is NOT a pseudo column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1919
     *      <LI> versionColumnPseudo - is a pseudo column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1920
     *      </UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1921
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1922
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1923
     * <p>The COLUMN_SIZE column represents the specified column size for the given column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1924
     * For numeric data, this is the maximum precision.  For character data, this is the length in characters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1925
     * For datetime datatypes, this is the length in characters of the String representation (assuming the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1926
     * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1927
     * this is the length in bytes. Null is returned for data types where the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1928
     * column size is not applicable.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1929
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1930
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1931
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1932
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1933
     * @param schema a schema name; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1934
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1935
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1936
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1937
     * @param table a table name; must match the table name as it is stored
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1938
     *        in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1939
     * @return a <code>ResultSet</code> object in which each row is a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1940
     *         column description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1941
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1942
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1943
    ResultSet getVersionColumns(String catalog, String schema,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1944
                                String table) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1945
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1946
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1947
     * Indicates that this version column may or may not be a pseudo column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1948
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1949
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1950
     * <code>PSEUDO_COLUMN</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1951
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1952
     * returned by the method <code>getVersionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1953
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1954
    int versionColumnUnknown    = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1955
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1956
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1957
     * Indicates that this version column is NOT a pseudo column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1958
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1959
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1960
     * <code>PSEUDO_COLUMN</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1961
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1962
     * returned by the method <code>getVersionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1963
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1964
    int versionColumnNotPseudo  = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1965
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1966
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1967
     * Indicates that this version column is a pseudo column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1968
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1969
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1970
     * <code>PSEUDO_COLUMN</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1971
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1972
     * returned by the method <code>getVersionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1973
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1974
    int versionColumnPseudo     = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1975
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1976
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1977
     * Retrieves a description of the given table's primary key columns.  They
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1978
     * are ordered by COLUMN_NAME.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1979
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1980
     * <P>Each primary key column description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1981
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1982
     *  <LI><B>TABLE_CAT</B> String {@code =>} table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1983
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1984
     *  <LI><B>TABLE_NAME</B> String {@code =>} table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1985
     *  <LI><B>COLUMN_NAME</B> String {@code =>} column name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1986
     *  <LI><B>KEY_SEQ</B> short {@code =>} sequence number within primary key( a value
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1987
     *  of 1 represents the first column of the primary key, a value of 2 would
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1988
     *  represent the second column within the primary key).
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  1989
     *  <LI><B>PK_NAME</B> String {@code =>} primary key name (may be <code>null</code>)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1990
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1991
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1992
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1993
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1994
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1995
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1996
     * @param schema a schema name; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1997
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1998
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  1999
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2000
     * @param table a table name; must match the table name as it is stored
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2001
     *        in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2002
     * @return <code>ResultSet</code> - each row is a primary key column description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2003
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2004
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2005
    ResultSet getPrimaryKeys(String catalog, String schema,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2006
                             String table) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2007
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2008
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2009
     * Retrieves a description of the primary key columns that are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2010
     * referenced by the given table's foreign key columns (the primary keys
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2011
     * imported by a table).  They are ordered by PKTABLE_CAT,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2012
     * PKTABLE_SCHEM, PKTABLE_NAME, and KEY_SEQ.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2013
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2014
     * <P>Each primary key column description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2015
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2016
     *  <LI><B>PKTABLE_CAT</B> String {@code =>} primary key table catalog
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2017
     *      being imported (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2018
     *  <LI><B>PKTABLE_SCHEM</B> String {@code =>} primary key table schema
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2019
     *      being imported (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2020
     *  <LI><B>PKTABLE_NAME</B> String {@code =>} primary key table name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2021
     *      being imported
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2022
     *  <LI><B>PKCOLUMN_NAME</B> String {@code =>} primary key column name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2023
     *      being imported
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2024
     *  <LI><B>FKTABLE_CAT</B> String {@code =>} foreign key table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2025
     *  <LI><B>FKTABLE_SCHEM</B> String {@code =>} foreign key table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2026
     *  <LI><B>FKTABLE_NAME</B> String {@code =>} foreign key table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2027
     *  <LI><B>FKCOLUMN_NAME</B> String {@code =>} foreign key column name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2028
     *  <LI><B>KEY_SEQ</B> short {@code =>} sequence number within a foreign key( a value
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2029
     *  of 1 represents the first column of the foreign key, a value of 2 would
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2030
     *  represent the second column within the foreign key).
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2031
     *  <LI><B>UPDATE_RULE</B> short {@code =>} What happens to a
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2032
     *       foreign key when the primary key is updated:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2033
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2034
     *      <LI> importedNoAction - do not allow update of primary
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2035
     *               key if it has been imported
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2036
     *      <LI> importedKeyCascade - change imported key to agree
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2037
     *               with primary key update
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2038
     *      <LI> importedKeySetNull - change imported key to <code>NULL</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2039
     *               if its primary key has been updated
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2040
     *      <LI> importedKeySetDefault - change imported key to default values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2041
     *               if its primary key has been updated
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2042
     *      <LI> importedKeyRestrict - same as importedKeyNoAction
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2043
     *                                 (for ODBC 2.x compatibility)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2044
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2045
     *  <LI><B>DELETE_RULE</B> short {@code =>} What happens to
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2046
     *      the foreign key when primary is deleted.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2047
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2048
     *      <LI> importedKeyNoAction - do not allow delete of primary
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2049
     *               key if it has been imported
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2050
     *      <LI> importedKeyCascade - delete rows that import a deleted key
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2051
     *      <LI> importedKeySetNull - change imported key to NULL if
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2052
     *               its primary key has been deleted
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2053
     *      <LI> importedKeyRestrict - same as importedKeyNoAction
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2054
     *                                 (for ODBC 2.x compatibility)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2055
     *      <LI> importedKeySetDefault - change imported key to default if
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2056
     *               its primary key has been deleted
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2057
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2058
     *  <LI><B>FK_NAME</B> String {@code =>} foreign key name (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2059
     *  <LI><B>PK_NAME</B> String {@code =>} primary key name (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2060
     *  <LI><B>DEFERRABILITY</B> short {@code =>} can the evaluation of foreign key
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2061
     *      constraints be deferred until commit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2062
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2063
     *      <LI> importedKeyInitiallyDeferred - see SQL92 for definition
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2064
     *      <LI> importedKeyInitiallyImmediate - see SQL92 for definition
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2065
     *      <LI> importedKeyNotDeferrable - see SQL92 for definition
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2066
     *      </UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2067
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2068
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2069
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2070
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2071
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2072
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2073
     * @param schema a schema name; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2074
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2075
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2076
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2077
     * @param table a table name; must match the table name as it is stored
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2078
     *        in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2079
     * @return <code>ResultSet</code> - each row is a primary key column description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2080
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2081
     * @see #getExportedKeys
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2082
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2083
    ResultSet getImportedKeys(String catalog, String schema,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2084
                              String table) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2085
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2086
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2087
     * For the column <code>UPDATE_RULE</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2088
     * indicates that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2089
     * when the primary key is updated, the foreign key (imported key)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2090
     * is changed to agree with it.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2091
     * For the column <code>DELETE_RULE</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2092
     * it indicates that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2093
     * when the primary key is deleted, rows that imported that key
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2094
     * are deleted.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2095
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2096
     * A possible value for the columns <code>UPDATE_RULE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2097
     * and <code>DELETE_RULE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2098
     * <code>ResultSet</code> objects returned by the methods
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2099
     * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2100
     * and <code>getCrossReference</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2101
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2102
    int importedKeyCascade      = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2103
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2104
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2105
     * For the column <code>UPDATE_RULE</code>, indicates that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2106
     * a primary key may not be updated if it has been imported by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2107
     * another table as a foreign key.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2108
     * For the column <code>DELETE_RULE</code>, indicates that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2109
     * a primary key may not be deleted if it has been imported by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2110
     * another table as a foreign key.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2111
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2112
     * A possible value for the columns <code>UPDATE_RULE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2113
     * and <code>DELETE_RULE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2114
     * <code>ResultSet</code> objects returned by the methods
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2115
     * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2116
     * and <code>getCrossReference</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2117
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2118
    int importedKeyRestrict = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2119
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2120
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2121
     * For the columns <code>UPDATE_RULE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2122
     * and <code>DELETE_RULE</code>, indicates that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2123
     * when the primary key is updated or deleted, the foreign key (imported key)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2124
     * is changed to <code>NULL</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2125
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2126
     * A possible value for the columns <code>UPDATE_RULE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2127
     * and <code>DELETE_RULE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2128
     * <code>ResultSet</code> objects returned by the methods
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2129
     * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2130
     * and <code>getCrossReference</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2131
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2132
    int importedKeySetNull  = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2133
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2134
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2135
     * For the columns <code>UPDATE_RULE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2136
     * and <code>DELETE_RULE</code>, indicates that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2137
     * if the primary key has been imported, it cannot be updated or deleted.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2138
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2139
     * A possible value for the columns <code>UPDATE_RULE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2140
     * and <code>DELETE_RULE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2141
     * <code>ResultSet</code> objects returned by the methods
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2142
     * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2143
     * and <code>getCrossReference</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2144
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2145
    int importedKeyNoAction = 3;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2146
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2147
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2148
     * For the columns <code>UPDATE_RULE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2149
     * and <code>DELETE_RULE</code>, indicates that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2150
     * if the primary key is updated or deleted, the foreign key (imported key)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2151
     * is set to the default value.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2152
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2153
     * A possible value for the columns <code>UPDATE_RULE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2154
     * and <code>DELETE_RULE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2155
     * <code>ResultSet</code> objects returned by the methods
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2156
     * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2157
     * and <code>getCrossReference</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2158
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2159
    int importedKeySetDefault  = 4;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2160
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2161
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2162
     * Indicates deferrability.  See SQL-92 for a definition.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2163
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2164
     * A possible value for the column <code>DEFERRABILITY</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2165
     * in the <code>ResultSet</code> objects returned by the methods
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2166
     * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2167
     * and <code>getCrossReference</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2168
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2169
    int importedKeyInitiallyDeferred  = 5;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2170
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2171
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2172
     * Indicates deferrability.  See SQL-92 for a definition.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2173
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2174
     * A possible value for the column <code>DEFERRABILITY</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2175
     * in the <code>ResultSet</code> objects returned by the methods
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2176
     * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2177
     * and <code>getCrossReference</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2178
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2179
    int importedKeyInitiallyImmediate  = 6;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2180
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2181
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2182
     * Indicates deferrability.  See SQL-92 for a definition.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2183
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2184
     * A possible value for the column <code>DEFERRABILITY</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2185
     * in the <code>ResultSet</code> objects returned by the methods
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2186
     * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2187
     * and <code>getCrossReference</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2188
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2189
    int importedKeyNotDeferrable  = 7;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2190
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2191
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2192
     * Retrieves a description of the foreign key columns that reference the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2193
     * given table's primary key columns (the foreign keys exported by a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2194
     * table).  They are ordered by FKTABLE_CAT, FKTABLE_SCHEM,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2195
     * FKTABLE_NAME, and KEY_SEQ.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2196
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2197
     * <P>Each foreign key column description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2198
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2199
     *  <LI><B>PKTABLE_CAT</B> String {@code =>} primary key table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2200
     *  <LI><B>PKTABLE_SCHEM</B> String {@code =>} primary key table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2201
     *  <LI><B>PKTABLE_NAME</B> String {@code =>} primary key table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2202
     *  <LI><B>PKCOLUMN_NAME</B> String {@code =>} primary key column name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2203
     *  <LI><B>FKTABLE_CAT</B> String {@code =>} foreign key table catalog (may be <code>null</code>)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2204
     *      being exported (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2205
     *  <LI><B>FKTABLE_SCHEM</B> String {@code =>} foreign key table schema (may be <code>null</code>)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2206
     *      being exported (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2207
     *  <LI><B>FKTABLE_NAME</B> String {@code =>} foreign key table name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2208
     *      being exported
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2209
     *  <LI><B>FKCOLUMN_NAME</B> String {@code =>} foreign key column name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2210
     *      being exported
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2211
     *  <LI><B>KEY_SEQ</B> short {@code =>} sequence number within foreign key( a value
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2212
     *  of 1 represents the first column of the foreign key, a value of 2 would
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2213
     *  represent the second column within the foreign key).
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2214
     *  <LI><B>UPDATE_RULE</B> short {@code =>} What happens to
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2215
     *       foreign key when primary is updated:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2216
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2217
     *      <LI> importedNoAction - do not allow update of primary
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2218
     *               key if it has been imported
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2219
     *      <LI> importedKeyCascade - change imported key to agree
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2220
     *               with primary key update
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2221
     *      <LI> importedKeySetNull - change imported key to <code>NULL</code> if
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2222
     *               its primary key has been updated
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2223
     *      <LI> importedKeySetDefault - change imported key to default values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2224
     *               if its primary key has been updated
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2225
     *      <LI> importedKeyRestrict - same as importedKeyNoAction
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2226
     *                                 (for ODBC 2.x compatibility)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2227
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2228
     *  <LI><B>DELETE_RULE</B> short {@code =>} What happens to
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2229
     *      the foreign key when primary is deleted.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2230
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2231
     *      <LI> importedKeyNoAction - do not allow delete of primary
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2232
     *               key if it has been imported
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2233
     *      <LI> importedKeyCascade - delete rows that import a deleted key
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2234
     *      <LI> importedKeySetNull - change imported key to <code>NULL</code> if
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2235
     *               its primary key has been deleted
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2236
     *      <LI> importedKeyRestrict - same as importedKeyNoAction
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2237
     *                                 (for ODBC 2.x compatibility)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2238
     *      <LI> importedKeySetDefault - change imported key to default if
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2239
     *               its primary key has been deleted
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2240
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2241
     *  <LI><B>FK_NAME</B> String {@code =>} foreign key name (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2242
     *  <LI><B>PK_NAME</B> String {@code =>} primary key name (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2243
     *  <LI><B>DEFERRABILITY</B> short {@code =>} can the evaluation of foreign key
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2244
     *      constraints be deferred until commit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2245
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2246
     *      <LI> importedKeyInitiallyDeferred - see SQL92 for definition
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2247
     *      <LI> importedKeyInitiallyImmediate - see SQL92 for definition
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2248
     *      <LI> importedKeyNotDeferrable - see SQL92 for definition
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2249
     *      </UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2250
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2251
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2252
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2253
     *        is stored in this database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2254
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2255
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2256
     * @param schema a schema name; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2257
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2258
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2259
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2260
     * @param table a table name; must match the table name as it is stored
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2261
     *        in this database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2262
     * @return a <code>ResultSet</code> object in which each row is a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2263
     *         foreign key column description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2264
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2265
     * @see #getImportedKeys
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2266
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2267
    ResultSet getExportedKeys(String catalog, String schema,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2268
                              String table) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2269
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2270
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2271
     * Retrieves a description of the foreign key columns in the given foreign key
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2272
     * table that reference the primary key or the columns representing a unique constraint of the  parent table (could be the same or a different table).
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2273
     * The number of columns returned from the parent table must match the number of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2274
     * columns that make up the foreign key.  They
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2275
     * are ordered by FKTABLE_CAT, FKTABLE_SCHEM, FKTABLE_NAME, and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2276
     * KEY_SEQ.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2277
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2278
     * <P>Each foreign key column description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2279
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2280
     *  <LI><B>PKTABLE_CAT</B> String {@code =>} parent key table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2281
     *  <LI><B>PKTABLE_SCHEM</B> String {@code =>} parent key table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2282
     *  <LI><B>PKTABLE_NAME</B> String {@code =>} parent key table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2283
     *  <LI><B>PKCOLUMN_NAME</B> String {@code =>} parent key column name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2284
     *  <LI><B>FKTABLE_CAT</B> String {@code =>} foreign key table catalog (may be <code>null</code>)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2285
     *      being exported (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2286
     *  <LI><B>FKTABLE_SCHEM</B> String {@code =>} foreign key table schema (may be <code>null</code>)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2287
     *      being exported (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2288
     *  <LI><B>FKTABLE_NAME</B> String {@code =>} foreign key table name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2289
     *      being exported
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2290
     *  <LI><B>FKCOLUMN_NAME</B> String {@code =>} foreign key column name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2291
     *      being exported
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2292
     *  <LI><B>KEY_SEQ</B> short {@code =>} sequence number within foreign key( a value
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2293
     *  of 1 represents the first column of the foreign key, a value of 2 would
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2294
     *  represent the second column within the foreign key).
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2295
     *  <LI><B>UPDATE_RULE</B> short {@code =>} What happens to
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2296
     *       foreign key when parent key is updated:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2297
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2298
     *      <LI> importedNoAction - do not allow update of parent
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2299
     *               key if it has been imported
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2300
     *      <LI> importedKeyCascade - change imported key to agree
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2301
     *               with parent key update
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2302
     *      <LI> importedKeySetNull - change imported key to <code>NULL</code> if
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2303
     *               its parent key has been updated
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2304
     *      <LI> importedKeySetDefault - change imported key to default values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2305
     *               if its parent key has been updated
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2306
     *      <LI> importedKeyRestrict - same as importedKeyNoAction
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2307
     *                                 (for ODBC 2.x compatibility)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2308
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2309
     *  <LI><B>DELETE_RULE</B> short {@code =>} What happens to
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2310
     *      the foreign key when parent key is deleted.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2311
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2312
     *      <LI> importedKeyNoAction - do not allow delete of parent
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2313
     *               key if it has been imported
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2314
     *      <LI> importedKeyCascade - delete rows that import a deleted key
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2315
     *      <LI> importedKeySetNull - change imported key to <code>NULL</code> if
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2316
     *               its primary key has been deleted
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2317
     *      <LI> importedKeyRestrict - same as importedKeyNoAction
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2318
     *                                 (for ODBC 2.x compatibility)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2319
     *      <LI> importedKeySetDefault - change imported key to default if
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2320
     *               its parent key has been deleted
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2321
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2322
     *  <LI><B>FK_NAME</B> String {@code =>} foreign key name (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2323
     *  <LI><B>PK_NAME</B> String {@code =>} parent key name (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2324
     *  <LI><B>DEFERRABILITY</B> short {@code =>} can the evaluation of foreign key
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2325
     *      constraints be deferred until commit
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2326
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2327
     *      <LI> importedKeyInitiallyDeferred - see SQL92 for definition
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2328
     *      <LI> importedKeyInitiallyImmediate - see SQL92 for definition
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2329
     *      <LI> importedKeyNotDeferrable - see SQL92 for definition
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2330
     *      </UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2331
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2332
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2333
     * @param parentCatalog a catalog name; must match the catalog name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2334
     * as it is stored in the database; "" retrieves those without a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2335
     * catalog; <code>null</code> means drop catalog name from the selection criteria
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2336
     * @param parentSchema a schema name; must match the schema name as
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2337
     * it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2338
     * <code>null</code> means drop schema name from the selection criteria
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2339
     * @param parentTable the name of the table that exports the key; must match
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2340
     * the table name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2341
     * @param foreignCatalog a catalog name; must match the catalog name as
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2342
     * it is stored in the database; "" retrieves those without a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2343
     * catalog; <code>null</code> means drop catalog name from the selection criteria
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2344
     * @param foreignSchema a schema name; must match the schema name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2345
     * is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2346
     * <code>null</code> means drop schema name from the selection criteria
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2347
     * @param foreignTable the name of the table that imports the key; must match
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2348
     * the table name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2349
     * @return <code>ResultSet</code> - each row is a foreign key column description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2350
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2351
     * @see #getImportedKeys
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2352
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2353
    ResultSet getCrossReference(
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2354
                                String parentCatalog, String parentSchema, String parentTable,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2355
                                String foreignCatalog, String foreignSchema, String foreignTable
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2356
                                ) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2357
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2358
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2359
     * Retrieves a description of all the data types supported by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2360
     * this database. They are ordered by DATA_TYPE and then by how
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2361
     * closely the data type maps to the corresponding JDBC SQL type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2362
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2363
     * <P>If the database supports SQL distinct types, then getTypeInfo() will return
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2364
     * a single row with a TYPE_NAME of DISTINCT and a DATA_TYPE of Types.DISTINCT.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2365
     * If the database supports SQL structured types, then getTypeInfo() will return
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2366
     * a single row with a TYPE_NAME of STRUCT and a DATA_TYPE of Types.STRUCT.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2367
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2368
     * <P>If SQL distinct or structured types are supported, then information on the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2369
     * individual types may be obtained from the getUDTs() method.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2370
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2371
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2372
     * <P>Each type description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2373
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2374
     *  <LI><B>TYPE_NAME</B> String {@code =>} Type name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2375
     *  <LI><B>DATA_TYPE</B> int {@code =>} SQL data type from java.sql.Types
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2376
     *  <LI><B>PRECISION</B> int {@code =>} maximum precision
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2377
     *  <LI><B>LITERAL_PREFIX</B> String {@code =>} prefix used to quote a literal
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2378
     *      (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2379
     *  <LI><B>LITERAL_SUFFIX</B> String {@code =>} suffix used to quote a literal
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  2380
     *  (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2381
     *  <LI><B>CREATE_PARAMS</B> String {@code =>} parameters used in creating
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2382
     *      the type (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2383
     *  <LI><B>NULLABLE</B> short {@code =>} can you use NULL for this type.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2384
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2385
     *      <LI> typeNoNulls - does not allow NULL values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2386
     *      <LI> typeNullable - allows NULL values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2387
     *      <LI> typeNullableUnknown - nullability unknown
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2388
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2389
     *  <LI><B>CASE_SENSITIVE</B> boolean{@code =>} is it case sensitive.
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2390
     *  <LI><B>SEARCHABLE</B> short {@code =>} can you use "WHERE" based on this type:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2391
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2392
     *      <LI> typePredNone - No support
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2393
     *      <LI> typePredChar - Only supported with WHERE .. LIKE
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2394
     *      <LI> typePredBasic - Supported except for WHERE .. LIKE
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2395
     *      <LI> typeSearchable - Supported for all WHERE ..
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2396
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2397
     *  <LI><B>UNSIGNED_ATTRIBUTE</B> boolean {@code =>} is it unsigned.
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2398
     *  <LI><B>FIXED_PREC_SCALE</B> boolean {@code =>} can it be a money value.
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2399
     *  <LI><B>AUTO_INCREMENT</B> boolean {@code =>} can it be used for an
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2400
     *      auto-increment value.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2401
     *  <LI><B>LOCAL_TYPE_NAME</B> String {@code =>} localized version of type name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2402
     *      (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2403
     *  <LI><B>MINIMUM_SCALE</B> short {@code =>} minimum scale supported
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2404
     *  <LI><B>MAXIMUM_SCALE</B> short {@code =>} maximum scale supported
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2405
     *  <LI><B>SQL_DATA_TYPE</B> int {@code =>} unused
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2406
     *  <LI><B>SQL_DATETIME_SUB</B> int {@code =>} unused
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2407
     *  <LI><B>NUM_PREC_RADIX</B> int {@code =>} usually 2 or 10
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2408
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2409
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2410
     * <p>The PRECISION column represents the maximum column size that the server supports for the given datatype.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2411
     * For numeric data, this is the maximum precision.  For character data, this is the length in characters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2412
     * For datetime datatypes, this is the length in characters of the String representation (assuming the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2413
     * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2414
     * this is the length in bytes. Null is returned for data types where the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2415
     * column size is not applicable.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2416
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2417
     * @return a <code>ResultSet</code> object in which each row is an SQL
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2418
     *         type description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2419
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2420
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2421
    ResultSet getTypeInfo() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2422
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2423
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2424
     * Indicates that a <code>NULL</code> value is NOT allowed for this
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2425
     * data type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2426
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2427
     * A possible value for column <code>NULLABLE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2428
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2429
     * <code>getTypeInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2430
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2431
    int typeNoNulls = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2432
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2433
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2434
     * Indicates that a <code>NULL</code> value is allowed for this
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2435
     * data type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2436
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2437
     * A possible value for column <code>NULLABLE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2438
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2439
     * <code>getTypeInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2440
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2441
    int typeNullable = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2442
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2443
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2444
     * Indicates that it is not known whether a <code>NULL</code> value
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2445
     * is allowed for this data type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2446
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2447
     * A possible value for column <code>NULLABLE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2448
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2449
     * <code>getTypeInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2450
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2451
    int typeNullableUnknown = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2452
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2453
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2454
     * Indicates that <code>WHERE</code> search clauses are not supported
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2455
     * for this type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2456
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2457
     * A possible value for column <code>SEARCHABLE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2458
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2459
     * <code>getTypeInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2460
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2461
    int typePredNone = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2462
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2463
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2464
     * Indicates that the data type
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2465
     * can be only be used in <code>WHERE</code> search clauses
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2466
     * that  use <code>LIKE</code> predicates.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2467
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2468
     * A possible value for column <code>SEARCHABLE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2469
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2470
     * <code>getTypeInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2471
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2472
    int typePredChar = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2473
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2474
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2475
     * Indicates that the data type can be only be used in <code>WHERE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2476
     * search clauses
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2477
     * that do not use <code>LIKE</code> predicates.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2478
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2479
     * A possible value for column <code>SEARCHABLE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2480
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2481
     * <code>getTypeInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2482
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2483
    int typePredBasic = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2484
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2485
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2486
     * Indicates that all <code>WHERE</code> search clauses can be
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2487
     * based on this type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2488
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2489
     * A possible value for column <code>SEARCHABLE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2490
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2491
     * <code>getTypeInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2492
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2493
    int typeSearchable  = 3;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2494
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2495
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2496
     * Retrieves a description of the given table's indices and statistics. They are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2497
     * ordered by NON_UNIQUE, TYPE, INDEX_NAME, and ORDINAL_POSITION.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2498
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2499
     * <P>Each index column description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2500
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2501
     *  <LI><B>TABLE_CAT</B> String {@code =>} table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2502
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2503
     *  <LI><B>TABLE_NAME</B> String {@code =>} table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2504
     *  <LI><B>NON_UNIQUE</B> boolean {@code =>} Can index values be non-unique.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2505
     *      false when TYPE is tableIndexStatistic
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2506
     *  <LI><B>INDEX_QUALIFIER</B> String {@code =>} index catalog (may be <code>null</code>);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2507
     *      <code>null</code> when TYPE is tableIndexStatistic
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2508
     *  <LI><B>INDEX_NAME</B> String {@code =>} index name; <code>null</code> when TYPE is
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2509
     *      tableIndexStatistic
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2510
     *  <LI><B>TYPE</B> short {@code =>} index type:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2511
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2512
     *      <LI> tableIndexStatistic - this identifies table statistics that are
25976
4de01a56e3ee 8054555: javadoc cleanup for java.sql and javax.sql
lancea
parents: 23590
diff changeset
  2513
     *           returned in conjunction with a table's index descriptions
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2514
     *      <LI> tableIndexClustered - this is a clustered index
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2515
     *      <LI> tableIndexHashed - this is a hashed index
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2516
     *      <LI> tableIndexOther - this is some other style of index
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2517
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2518
     *  <LI><B>ORDINAL_POSITION</B> short {@code =>} column sequence number
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2519
     *      within index; zero when TYPE is tableIndexStatistic
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2520
     *  <LI><B>COLUMN_NAME</B> String {@code =>} column name; <code>null</code> when TYPE is
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2521
     *      tableIndexStatistic
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2522
     *  <LI><B>ASC_OR_DESC</B> String {@code =>} column sort sequence, "A" {@code =>} ascending,
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2523
     *      "D" {@code =>} descending, may be <code>null</code> if sort sequence is not supported;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2524
     *      <code>null</code> when TYPE is tableIndexStatistic
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2525
     *  <LI><B>CARDINALITY</B> long {@code =>} When TYPE is tableIndexStatistic, then
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2526
     *      this is the number of rows in the table; otherwise, it is the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2527
     *      number of unique values in the index.
25976
4de01a56e3ee 8054555: javadoc cleanup for java.sql and javax.sql
lancea
parents: 23590
diff changeset
  2528
     *  <LI><B>PAGES</B> long {@code =>} When TYPE is  tableIndexStatistic then
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2529
     *      this is the number of pages used for the table, otherwise it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2530
     *      is the number of pages used for the current index.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2531
     *  <LI><B>FILTER_CONDITION</B> String {@code =>} Filter condition, if any.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2532
     *      (may be <code>null</code>)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2533
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2534
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2535
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2536
     *        is stored in this database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2537
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2538
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2539
     * @param schema a schema name; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2540
     *        as it is stored in this database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2541
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2542
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2543
     * @param table a table name; must match the table name as it is stored
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2544
     *        in this database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2545
     * @param unique when true, return only indices for unique values;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2546
     *     when false, return indices regardless of whether unique or not
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2547
     * @param approximate when true, result is allowed to reflect approximate
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2548
     *     or out of data values; when false, results are requested to be
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2549
     *     accurate
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2550
     * @return <code>ResultSet</code> - each row is an index column description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2551
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2552
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2553
    ResultSet getIndexInfo(String catalog, String schema, String table,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2554
                           boolean unique, boolean approximate)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2555
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2556
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2557
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2558
     * Indicates that this column contains table statistics that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2559
     * are returned in conjunction with a table's index descriptions.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2560
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2561
     * A possible value for column <code>TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2562
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2563
     * <code>getIndexInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2564
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2565
    short tableIndexStatistic = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2566
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2567
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2568
     * Indicates that this table index is a clustered index.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2569
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2570
     * A possible value for column <code>TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2571
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2572
     * <code>getIndexInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2573
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2574
    short tableIndexClustered = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2575
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2576
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2577
     * Indicates that this table index is a hashed index.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2578
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2579
     * A possible value for column <code>TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2580
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2581
     * <code>getIndexInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2582
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2583
    short tableIndexHashed    = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2584
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2585
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2586
     * Indicates that this table index is not a clustered
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2587
     * index, a hashed index, or table statistics;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2588
     * it is something other than these.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2589
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2590
     * A possible value for column <code>TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2591
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2592
     * <code>getIndexInfo</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2593
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2594
    short tableIndexOther     = 3;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2595
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2596
    //--------------------------JDBC 2.0-----------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2597
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2598
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2599
     * Retrieves whether this database supports the given result set type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2600
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2601
     * @param type defined in <code>java.sql.ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2602
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2603
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2604
     * @see Connection
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2605
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2606
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2607
    boolean supportsResultSetType(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2608
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2609
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2610
     * Retrieves whether this database supports the given concurrency type
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2611
     * in combination with the given result set type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2612
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2613
     * @param type defined in <code>java.sql.ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2614
     * @param concurrency type defined in <code>java.sql.ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2615
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2616
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2617
     * @see Connection
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2618
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2619
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2620
    boolean supportsResultSetConcurrency(int type, int concurrency)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2621
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2622
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2623
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2624
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2625
     * Retrieves whether for the given type of <code>ResultSet</code> object,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2626
     * the result set's own updates are visible.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2627
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2628
     * @param type the <code>ResultSet</code> type; one of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2629
     *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2630
     *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2631
     *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2632
     * @return <code>true</code> if updates are visible for the given result set type;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2633
     *        <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2634
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2635
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2636
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2637
    boolean ownUpdatesAreVisible(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2638
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2639
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2640
     * Retrieves whether a result set's own deletes are visible.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2641
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2642
     * @param type the <code>ResultSet</code> type; one of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2643
     *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2644
     *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2645
     *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2646
     * @return <code>true</code> if deletes are visible for the given result set type;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2647
     *        <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2648
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2649
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2650
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2651
    boolean ownDeletesAreVisible(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2652
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2653
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2654
     * Retrieves whether a result set's own inserts are visible.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2655
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2656
     * @param type the <code>ResultSet</code> type; one of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2657
     *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2658
     *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2659
     *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2660
     * @return <code>true</code> if inserts are visible for the given result set type;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2661
     *        <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2662
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2663
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2664
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2665
    boolean ownInsertsAreVisible(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2666
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2667
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2668
     * Retrieves whether updates made by others are visible.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2669
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2670
     * @param type the <code>ResultSet</code> type; one of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2671
     *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2672
     *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2673
     *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2674
     * @return <code>true</code> if updates made by others
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2675
     *        are visible for the given result set type;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2676
     *        <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2677
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2678
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2679
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2680
    boolean othersUpdatesAreVisible(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2681
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2682
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2683
     * Retrieves whether deletes made by others are visible.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2684
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2685
     * @param type the <code>ResultSet</code> type; one of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2686
     *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2687
     *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2688
     *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2689
     * @return <code>true</code> if deletes made by others
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2690
     *        are visible for the given result set type;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2691
     *        <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2692
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2693
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2694
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2695
    boolean othersDeletesAreVisible(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2696
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2697
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2698
     * Retrieves whether inserts made by others are visible.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2699
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2700
     * @param type the <code>ResultSet</code> type; one of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2701
     *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2702
     *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2703
     *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2704
     * @return <code>true</code> if inserts made by others
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2705
     *         are visible for the given result set type;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2706
     *         <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2707
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2708
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2709
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2710
    boolean othersInsertsAreVisible(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2711
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2712
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2713
     * Retrieves whether or not a visible row update can be detected by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2714
     * calling the method <code>ResultSet.rowUpdated</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2715
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2716
     * @param type the <code>ResultSet</code> type; one of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2717
     *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2718
     *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2719
     *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2720
     * @return <code>true</code> if changes are detected by the result set type;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2721
     *         <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2722
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2723
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2724
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2725
    boolean updatesAreDetected(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2726
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2727
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2728
     * Retrieves whether or not a visible row delete can be detected by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2729
     * calling the method <code>ResultSet.rowDeleted</code>.  If the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2730
     * <code>deletesAreDetected</code> returns <code>false</code>, it means that
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2731
     * deleted rows are removed from the result set.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2732
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2733
     * @param type the <code>ResultSet</code> type; one of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2734
     *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2735
     *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2736
     *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2737
     * @return <code>true</code> if deletes are detected by the given result set type;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2738
     *         <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2739
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2740
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2741
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2742
    boolean deletesAreDetected(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2743
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2744
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2745
     * Retrieves whether or not a visible row insert can be detected
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2746
     * by calling the method <code>ResultSet.rowInserted</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2747
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2748
     * @param type the <code>ResultSet</code> type; one of
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2749
     *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2750
     *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2751
     *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2752
     * @return <code>true</code> if changes are detected by the specified result
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2753
     *         set type; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2754
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2755
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2756
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2757
    boolean insertsAreDetected(int type) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2758
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2759
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2760
     * Retrieves whether this database supports batch updates.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2761
     *
15278
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  2762
     * @return <code>true</code> if this database supports batch updates;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2763
     *         <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2764
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2765
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2766
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2767
    boolean supportsBatchUpdates() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2768
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2769
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2770
     * Retrieves a description of the user-defined types (UDTs) defined
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2771
     * in a particular schema.  Schema-specific UDTs may have type
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2772
     * <code>JAVA_OBJECT</code>, <code>STRUCT</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2773
     * or <code>DISTINCT</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2774
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2775
     * <P>Only types matching the catalog, schema, type name and type
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2776
     * criteria are returned.  They are ordered by <code>DATA_TYPE</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2777
     * <code>TYPE_CAT</code>, <code>TYPE_SCHEM</code>  and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2778
     * <code>TYPE_NAME</code>.  The type name parameter may be a fully-qualified
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2779
     * name.  In this case, the catalog and schemaPattern parameters are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2780
     * ignored.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2781
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2782
     * <P>Each type description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2783
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2784
     *  <LI><B>TYPE_CAT</B> String {@code =>} the type's catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2785
     *  <LI><B>TYPE_SCHEM</B> String {@code =>} type's schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2786
     *  <LI><B>TYPE_NAME</B> String {@code =>} type name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2787
     *  <LI><B>CLASS_NAME</B> String {@code =>} Java class name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2788
     *  <LI><B>DATA_TYPE</B> int {@code =>} type value defined in java.sql.Types.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2789
     *     One of JAVA_OBJECT, STRUCT, or DISTINCT
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2790
     *  <LI><B>REMARKS</B> String {@code =>} explanatory comment on the type
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2791
     *  <LI><B>BASE_TYPE</B> short {@code =>} type code of the source type of a
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2792
     *     DISTINCT type or the type that implements the user-generated
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2793
     *     reference type of the SELF_REFERENCING_COLUMN of a structured
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2794
     *     type as defined in java.sql.Types (<code>null</code> if DATA_TYPE is not
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2795
     *     DISTINCT or not STRUCT with REFERENCE_GENERATION = USER_DEFINED)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2796
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2797
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2798
     * <P><B>Note:</B> If the driver does not support UDTs, an empty
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2799
     * result set is returned.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2800
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2801
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2802
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2803
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2804
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2805
     * @param schemaPattern a schema pattern name; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2806
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2807
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2808
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2809
     * @param typeNamePattern a type name pattern; must match the type name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2810
     *        as it is stored in the database; may be a fully qualified name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2811
     * @param types a list of user-defined types (JAVA_OBJECT,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2812
     *        STRUCT, or DISTINCT) to include; <code>null</code> returns all types
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2813
     * @return <code>ResultSet</code> object in which each row describes a UDT
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2814
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2815
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2816
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2817
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2818
    ResultSet getUDTs(String catalog, String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2819
                      String typeNamePattern, int[] types)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2820
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2821
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2822
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2823
     * Retrieves the connection that produced this metadata object.
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  2824
     *
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2825
     * @return the connection that produced this metadata object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2826
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2827
     * @since 1.2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2828
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2829
    Connection getConnection() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2830
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2831
    // ------------------- JDBC 3.0 -------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2832
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2833
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2834
     * Retrieves whether this database supports savepoints.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2835
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2836
     * @return <code>true</code> if savepoints are supported;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2837
     *         <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2838
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2839
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2840
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2841
    boolean supportsSavepoints() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2842
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2843
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2844
     * Retrieves whether this database supports named parameters to callable
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2845
     * statements.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2846
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2847
     * @return <code>true</code> if named parameters are supported;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2848
     *         <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2849
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2850
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2851
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2852
    boolean supportsNamedParameters() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2853
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2854
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2855
     * Retrieves whether it is possible to have multiple <code>ResultSet</code> objects
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2856
     * returned from a <code>CallableStatement</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2857
     * simultaneously.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2858
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2859
     * @return <code>true</code> if a <code>CallableStatement</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2860
     *         can return multiple <code>ResultSet</code> objects
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2861
     *         simultaneously; <code>false</code> otherwise
25976
4de01a56e3ee 8054555: javadoc cleanup for java.sql and javax.sql
lancea
parents: 23590
diff changeset
  2862
     * @exception SQLException if a database access error occurs
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2863
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2864
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2865
    boolean supportsMultipleOpenResults() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2866
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2867
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2868
     * Retrieves whether auto-generated keys can be retrieved after
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2869
     * a statement has been executed
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2870
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2871
     * @return <code>true</code> if auto-generated keys can be retrieved
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2872
     *         after a statement has executed; <code>false</code> otherwise
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  2873
     * <p>If <code>true</code> is returned, the JDBC driver must support the
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2874
     * returning of auto-generated keys for at least SQL INSERT statements
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  2875
     *
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2876
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2877
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2878
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2879
    boolean supportsGetGeneratedKeys() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2880
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2881
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2882
     * Retrieves a description of the user-defined type (UDT) hierarchies defined in a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2883
     * particular schema in this database. Only the immediate super type/
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2884
     * sub type relationship is modeled.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2885
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2886
     * Only supertype information for UDTs matching the catalog,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2887
     * schema, and type name is returned. The type name parameter
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2888
     * may be a fully-qualified name. When the UDT name supplied is a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2889
     * fully-qualified name, the catalog and schemaPattern parameters are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2890
     * ignored.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2891
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2892
     * If a UDT does not have a direct super type, it is not listed here.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2893
     * A row of the <code>ResultSet</code> object returned by this method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2894
     * describes the designated UDT and a direct supertype. A row has the following
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2895
     * columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2896
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2897
     *  <LI><B>TYPE_CAT</B> String {@code =>} the UDT's catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2898
     *  <LI><B>TYPE_SCHEM</B> String {@code =>} UDT's schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2899
     *  <LI><B>TYPE_NAME</B> String {@code =>} type name of the UDT
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2900
     *  <LI><B>SUPERTYPE_CAT</B> String {@code =>} the direct super type's catalog
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2901
     *                           (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2902
     *  <LI><B>SUPERTYPE_SCHEM</B> String {@code =>} the direct super type's schema
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2903
     *                             (may be <code>null</code>)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2904
     *  <LI><B>SUPERTYPE_NAME</B> String {@code =>} the direct super type's name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2905
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2906
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2907
     * <P><B>Note:</B> If the driver does not support type hierarchies, an
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2908
     * empty result set is returned.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2909
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2910
     * @param catalog a catalog name; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2911
     *        <code>null</code> means drop catalog name from the selection criteria
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2912
     * @param schemaPattern a schema name pattern; "" retrieves those
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2913
     *        without a schema
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2914
     * @param typeNamePattern a UDT name pattern; may be a fully-qualified
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2915
     *        name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2916
     * @return a <code>ResultSet</code> object in which a row gives information
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2917
     *         about the designated UDT
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2918
     * @throws SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2919
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2920
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2921
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2922
    ResultSet getSuperTypes(String catalog, String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2923
                            String typeNamePattern) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2924
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2925
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2926
     * Retrieves a description of the table hierarchies defined in a particular
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2927
     * schema in this database.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2928
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2929
     * <P>Only supertable information for tables matching the catalog, schema
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2930
     * and table name are returned. The table name parameter may be a fully-
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2931
     * qualified name, in which case, the catalog and schemaPattern parameters
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2932
     * are ignored. If a table does not have a super table, it is not listed here.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2933
     * Supertables have to be defined in the same catalog and schema as the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2934
     * sub tables. Therefore, the type description does not need to include
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2935
     * this information for the supertable.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2936
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2937
     * <P>Each type description has the following columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2938
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2939
     *  <LI><B>TABLE_CAT</B> String {@code =>} the type's catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2940
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} type's schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2941
     *  <LI><B>TABLE_NAME</B> String {@code =>} type name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  2942
     *  <LI><B>SUPERTABLE_NAME</B> String {@code =>} the direct super type's name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2943
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2944
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2945
     * <P><B>Note:</B> If the driver does not support type hierarchies, an
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2946
     * empty result set is returned.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2947
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2948
     * @param catalog a catalog name; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2949
     *        <code>null</code> means drop catalog name from the selection criteria
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2950
     * @param schemaPattern a schema name pattern; "" retrieves those
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2951
     *        without a schema
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2952
     * @param tableNamePattern a table name pattern; may be a fully-qualified
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2953
     *        name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2954
     * @return a <code>ResultSet</code> object in which each row is a type description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2955
     * @throws SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2956
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2957
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2958
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2959
    ResultSet getSuperTables(String catalog, String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2960
                             String tableNamePattern) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2961
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2962
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2963
     * Indicates that <code>NULL</code> values might not be allowed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2964
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2965
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2966
     * <code>NULLABLE</code> in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2967
     * returned by the method <code>getAttributes</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2968
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2969
    short attributeNoNulls = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2970
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2971
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2972
     * Indicates that <code>NULL</code> values are definitely allowed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2973
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2974
     * A possible value for the column <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2975
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2976
     * returned by the method <code>getAttributes</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2977
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2978
    short attributeNullable = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2979
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2980
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2981
     * Indicates that whether <code>NULL</code> values are allowed is not
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2982
     * known.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2983
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2984
     * A possible value for the column <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2985
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2986
     * returned by the method <code>getAttributes</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2987
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2988
    short attributeNullableUnknown = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2989
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2990
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2991
     * Retrieves a description of the given attribute of the given type
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2992
     * for a user-defined type (UDT) that is available in the given schema
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2993
     * and catalog.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2994
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2995
     * Descriptions are returned only for attributes of UDTs matching the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2996
     * catalog, schema, type, and attribute name criteria. They are ordered by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2997
     * <code>TYPE_CAT</code>, <code>TYPE_SCHEM</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2998
     * <code>TYPE_NAME</code> and <code>ORDINAL_POSITION</code>. This description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  2999
     * does not contain inherited attributes.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3000
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3001
     * The <code>ResultSet</code> object that is returned has the following
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3002
     * columns:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3003
     * <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3004
     *  <LI><B>TYPE_CAT</B> String {@code =>} type catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3005
     *  <LI><B>TYPE_SCHEM</B> String {@code =>} type schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3006
     *  <LI><B>TYPE_NAME</B> String {@code =>} type name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3007
     *  <LI><B>ATTR_NAME</B> String {@code =>} attribute name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3008
     *  <LI><B>DATA_TYPE</B> int {@code =>} attribute type SQL type from java.sql.Types
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3009
     *  <LI><B>ATTR_TYPE_NAME</B> String {@code =>} Data source dependent type name.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3010
     *  For a UDT, the type name is fully qualified. For a REF, the type name is
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3011
     *  fully qualified and represents the target type of the reference type.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3012
     *  <LI><B>ATTR_SIZE</B> int {@code =>} column size.  For char or date
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3013
     *      types this is the maximum number of characters; for numeric or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3014
     *      decimal types this is precision.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3015
     *  <LI><B>DECIMAL_DIGITS</B> int {@code =>} the number of fractional digits. Null is returned for data types where
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3016
     * DECIMAL_DIGITS is not applicable.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3017
     *  <LI><B>NUM_PREC_RADIX</B> int {@code =>} Radix (typically either 10 or 2)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3018
     *  <LI><B>NULLABLE</B> int {@code =>} whether NULL is allowed
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3019
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3020
     *      <LI> attributeNoNulls - might not allow NULL values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3021
     *      <LI> attributeNullable - definitely allows NULL values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3022
     *      <LI> attributeNullableUnknown - nullability unknown
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3023
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3024
     *  <LI><B>REMARKS</B> String {@code =>} comment describing column (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3025
     *  <LI><B>ATTR_DEF</B> String {@code =>} default value (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3026
     *  <LI><B>SQL_DATA_TYPE</B> int {@code =>} unused
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3027
     *  <LI><B>SQL_DATETIME_SUB</B> int {@code =>} unused
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3028
     *  <LI><B>CHAR_OCTET_LENGTH</B> int {@code =>} for char types the
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3029
     *       maximum number of bytes in the column
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3030
     *  <LI><B>ORDINAL_POSITION</B> int {@code =>} index of the attribute in the UDT
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3031
     *      (starting at 1)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3032
     *  <LI><B>IS_NULLABLE</B> String  {@code =>} ISO rules are used to determine
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3033
     * the nullability for a attribute.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3034
     *       <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3035
     *       <LI> YES           --- if the attribute can include NULLs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3036
     *       <LI> NO            --- if the attribute cannot include NULLs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3037
     *       <LI> empty string  --- if the nullability for the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3038
     * attribute is unknown
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3039
     *       </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3040
     *  <LI><B>SCOPE_CATALOG</B> String {@code =>} catalog of table that is the
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3041
     *      scope of a reference attribute (<code>null</code> if DATA_TYPE isn't REF)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3042
     *  <LI><B>SCOPE_SCHEMA</B> String {@code =>} schema of table that is the
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3043
     *      scope of a reference attribute (<code>null</code> if DATA_TYPE isn't REF)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3044
     *  <LI><B>SCOPE_TABLE</B> String {@code =>} table name that is the scope of a
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3045
     *      reference attribute (<code>null</code> if the DATA_TYPE isn't REF)
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3046
     * <LI><B>SOURCE_DATA_TYPE</B> short {@code =>} source type of a distinct type or user-generated
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3047
     *      Ref type,SQL type from java.sql.Types (<code>null</code> if DATA_TYPE
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3048
     *      isn't DISTINCT or user-generated REF)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3049
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3050
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3051
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3052
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3053
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3054
     * @param schemaPattern a schema name pattern; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3055
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3056
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3057
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3058
     * @param typeNamePattern a type name pattern; must match the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3059
     *        type name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3060
     * @param attributeNamePattern an attribute name pattern; must match the attribute
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3061
     *        name as it is declared in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3062
     * @return a <code>ResultSet</code> object in which each row is an
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3063
     *         attribute description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3064
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3065
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3066
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3067
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3068
    ResultSet getAttributes(String catalog, String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3069
                            String typeNamePattern, String attributeNamePattern)
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3070
        throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3071
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3072
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3073
     * Retrieves whether this database supports the given result set holdability.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3074
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3075
     * @param holdability one of the following constants:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3076
     *          <code>ResultSet.HOLD_CURSORS_OVER_COMMIT</code> or
18564
f9db68ff2cbb 8017471: Fix JDBC -Xdoclint public errors
lancea
parents: 18156
diff changeset
  3077
     *          <code>ResultSet.CLOSE_CURSORS_AT_COMMIT</code>
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3078
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3079
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3080
     * @see Connection
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3081
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3082
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3083
    boolean supportsResultSetHoldability(int holdability) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3084
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3085
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3086
     * Retrieves this database's default holdability for <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3087
     * objects.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3088
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3089
     * @return the default holdability; either
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3090
     *         <code>ResultSet.HOLD_CURSORS_OVER_COMMIT</code> or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3091
     *         <code>ResultSet.CLOSE_CURSORS_AT_COMMIT</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3092
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3093
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3094
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3095
    int getResultSetHoldability() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3096
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3097
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3098
     * Retrieves the major version number of the underlying database.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3099
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3100
     * @return the underlying database's major version
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3101
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3102
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3103
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3104
    int getDatabaseMajorVersion() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3105
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3106
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3107
     * Retrieves the minor version number of the underlying database.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3108
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3109
     * @return underlying database's minor version
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3110
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3111
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3112
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3113
    int getDatabaseMinorVersion() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3114
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3115
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3116
     * Retrieves the major JDBC version number for this
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3117
     * driver.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3118
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3119
     * @return JDBC version major number
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3120
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3121
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3122
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3123
    int getJDBCMajorVersion() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3124
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3125
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3126
     * Retrieves the minor JDBC version number for this
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3127
     * driver.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3128
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3129
     * @return JDBC version minor number
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3130
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3131
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3132
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3133
    int getJDBCMinorVersion() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3134
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3135
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3136
     *  A possible return value for the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3137
     * <code>DatabaseMetaData.getSQLStateType</code> which is used to indicate
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3138
     * whether the value returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3139
     * <code>SQLException.getSQLState</code> is an
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3140
     * X/Open (now know as Open Group) SQL CLI SQLSTATE value.
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  3141
     *
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3142
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3143
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3144
    int sqlStateXOpen = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3145
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3146
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3147
     *  A possible return value for the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3148
     * <code>DatabaseMetaData.getSQLStateType</code> which is used to indicate
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3149
     * whether the value returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3150
     * <code>SQLException.getSQLState</code> is an SQLSTATE value.
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  3151
     *
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3152
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3153
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3154
    int sqlStateSQL = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3155
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3156
     /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3157
     *  A possible return value for the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3158
     * <code>DatabaseMetaData.getSQLStateType</code> which is used to indicate
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3159
     * whether the value returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3160
     * <code>SQLException.getSQLState</code> is an SQL99 SQLSTATE value.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3161
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3162
     * <b>Note:</b>This constant remains only for compatibility reasons. Developers
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3163
     * should use the constant <code>sqlStateSQL</code> instead.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3164
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3165
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3166
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3167
    int sqlStateSQL99 = sqlStateSQL;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3168
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3169
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3170
     * Indicates whether the SQLSTATE returned by <code>SQLException.getSQLState</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3171
     * is X/Open (now known as Open Group) SQL CLI or SQL:2003.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3172
     * @return the type of SQLSTATE; one of:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3173
     *        sqlStateXOpen or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3174
     *        sqlStateSQL
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3175
     * @throws SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3176
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3177
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3178
    int getSQLStateType() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3179
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3180
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3181
     * Indicates whether updates made to a LOB are made on a copy or directly
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3182
     * to the LOB.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3183
     * @return <code>true</code> if updates are made to a copy of the LOB;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3184
     *         <code>false</code> if updates are made directly to the LOB
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3185
     * @throws SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3186
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3187
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3188
    boolean locatorsUpdateCopy() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3189
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3190
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3191
     * Retrieves whether this database supports statement pooling.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3192
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3193
     * @return <code>true</code> if so; <code>false</code> otherwise
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3194
     * @throws SQLException if a database access error occurs
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3195
     * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3196
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3197
    boolean supportsStatementPooling() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3198
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3199
    //------------------------- JDBC 4.0 -----------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3200
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3201
    /**
45331
f829a12aff54 8180728: DatabaseMeta.getRowIdLifetime returns an enum but javadoc refers to int
lancea
parents: 44256
diff changeset
  3202
     * Indicates whether this data source supports the SQL {@code  ROWID} type,
f829a12aff54 8180728: DatabaseMeta.getRowIdLifetime returns an enum but javadoc refers to int
lancea
parents: 44256
diff changeset
  3203
     * and the lifetime for which a {@link  RowId} object remains valid.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3204
     *
45331
f829a12aff54 8180728: DatabaseMeta.getRowIdLifetime returns an enum but javadoc refers to int
lancea
parents: 44256
diff changeset
  3205
     * @return the status indicating the lifetime of a {@code  RowId}
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3206
     * @throws SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3207
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3208
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3209
    RowIdLifetime getRowIdLifetime() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3210
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3211
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3212
     * Retrieves the schema names available in this database.  The results
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3213
     * are ordered by <code>TABLE_CATALOG</code> and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3214
     * <code>TABLE_SCHEM</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3215
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3216
     * <P>The schema columns are:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3217
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3218
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} schema name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3219
     *  <LI><B>TABLE_CATALOG</B> String {@code =>} catalog name (may be <code>null</code>)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3220
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3221
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3222
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3223
     * @param catalog a catalog name; must match the catalog name as it is stored
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3224
     * in the database;"" retrieves those without a catalog; null means catalog
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3225
     * name should not be used to narrow down the search.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3226
     * @param schemaPattern a schema name; must match the schema name as it is
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3227
     * stored in the database; null means
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3228
     * schema name should not be used to narrow down the search.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3229
     * @return a <code>ResultSet</code> object in which each row is a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3230
     *         schema description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3231
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3232
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3233
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3234
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3235
    ResultSet getSchemas(String catalog, String schemaPattern) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3236
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3237
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3238
     * Retrieves whether this database supports invoking user-defined or vendor functions
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3239
     * using the stored procedure escape syntax.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3240
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3241
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3242
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3243
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3244
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3245
    boolean supportsStoredFunctionsUsingCallSyntax() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3246
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3247
    /**
21278
ef8a3a2a72f2 8022746: List of spelling errors in API doc
malenkov
parents: 20880
diff changeset
  3248
     * Retrieves whether a <code>SQLException</code> while autoCommit is <code>true</code> indicates
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3249
     * that all open ResultSets are closed, even ones that are holdable.  When a <code>SQLException</code> occurs while
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3250
     * autocommit is <code>true</code>, it is vendor specific whether the JDBC driver responds with a commit operation, a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3251
     * rollback operation, or by doing neither a commit nor a rollback.  A potential result of this difference
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3252
     * is in whether or not holdable ResultSets are closed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3253
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3254
     * @return <code>true</code> if so; <code>false</code> otherwise
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3255
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3256
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3257
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3258
    boolean autoCommitFailureClosesAllResultSets() throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3259
        /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3260
         * Retrieves a list of the client info properties
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3261
         * that the driver supports.  The result set contains the following columns
20880
1b610151b316 8026812: doclint clean up for java.sql and javax.sql
lancea
parents: 18564
diff changeset
  3262
         *
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3263
         * <ol>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3264
         * <li><b>NAME</b> String{@code =>} The name of the client info property<br>
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3265
         * <li><b>MAX_LEN</b> int{@code =>} The maximum length of the value for the property<br>
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3266
         * <li><b>DEFAULT_VALUE</b> String{@code =>} The default value of the property<br>
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3267
         * <li><b>DESCRIPTION</b> String{@code =>} A description of the property.  This will typically
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3268
         *                                              contain information as to where this property is
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3269
         *                                              stored in the database.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3270
         * </ol>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3271
         * <p>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3272
         * The <code>ResultSet</code> is sorted by the NAME column
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  3273
         *
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3274
         * @return      A <code>ResultSet</code> object; each row is a supported client info
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3275
         * property
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  3276
         *
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3277
         *  @exception SQLException if a database access error occurs
23590
ffd8b0b70511 8038493: Tidy warnings cleanup for java.sql
yan
parents: 21278
diff changeset
  3278
         *
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3279
         * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3280
         */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3281
        ResultSet getClientInfoProperties()
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3282
                throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3283
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3284
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3285
     * Retrieves a description of the  system and user functions available
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3286
     * in the given catalog.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3287
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3288
     * Only system and user function descriptions matching the schema and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3289
     * function name criteria are returned.  They are ordered by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3290
     * <code>FUNCTION_CAT</code>, <code>FUNCTION_SCHEM</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3291
     * <code>FUNCTION_NAME</code> and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3292
     * <code>SPECIFIC_ NAME</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3293
     *
25976
4de01a56e3ee 8054555: javadoc cleanup for java.sql and javax.sql
lancea
parents: 23590
diff changeset
  3294
     * <P>Each function description has the following columns:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3295
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3296
     *  <LI><B>FUNCTION_CAT</B> String {@code =>} function catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3297
     *  <LI><B>FUNCTION_SCHEM</B> String {@code =>} function schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3298
     *  <LI><B>FUNCTION_NAME</B> String {@code =>} function name.  This is the name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3299
     * used to invoke the function
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3300
     *  <LI><B>REMARKS</B> String {@code =>} explanatory comment on the function
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3301
     * <LI><B>FUNCTION_TYPE</B> short {@code =>} kind of function:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3302
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3303
     *      <LI>functionResultUnknown - Cannot determine if a return value
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3304
     *       or table will be returned
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3305
     *      <LI> functionNoTable- Does not return a table
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3306
     *      <LI> functionReturnsTable - Returns a table
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3307
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3308
     *  <LI><B>SPECIFIC_NAME</B> String  {@code =>} the name which uniquely identifies
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3309
     *  this function within its schema.  This is a user specified, or DBMS
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3310
     * generated, name that may be different then the <code>FUNCTION_NAME</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3311
     * for example with overload functions
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3312
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3313
     * <p>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3314
     * A user may not have permission to execute any of the functions that are
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3315
     * returned by <code>getFunctions</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3316
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3317
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3318
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3319
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3320
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3321
     * @param schemaPattern a schema name pattern; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3322
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3323
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3324
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3325
     * @param functionNamePattern a function name pattern; must match the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3326
     *        function name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3327
     * @return <code>ResultSet</code> - each row is a function description
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3328
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3329
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3330
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3331
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3332
    ResultSet getFunctions(String catalog, String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3333
                            String functionNamePattern) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3334
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3335
     * Retrieves a description of the given catalog's system or user
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3336
     * function parameters and return type.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3337
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3338
     * <P>Only descriptions matching the schema,  function and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3339
     * parameter name criteria are returned. They are ordered by
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3340
     * <code>FUNCTION_CAT</code>, <code>FUNCTION_SCHEM</code>,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3341
     * <code>FUNCTION_NAME</code> and
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3342
     * <code>SPECIFIC_ NAME</code>. Within this, the return value,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3343
     * if any, is first. Next are the parameter descriptions in call
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3344
     * order. The column descriptions follow in column number order.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3345
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3346
     * <P>Each row in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3347
     * is a parameter description, column description or
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3348
     * return type description with the following fields:
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3349
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3350
     *  <LI><B>FUNCTION_CAT</B> String {@code =>} function catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3351
     *  <LI><B>FUNCTION_SCHEM</B> String {@code =>} function schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3352
     *  <LI><B>FUNCTION_NAME</B> String {@code =>} function name.  This is the name
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3353
     * used to invoke the function
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3354
     *  <LI><B>COLUMN_NAME</B> String {@code =>} column/parameter name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3355
     *  <LI><B>COLUMN_TYPE</B> Short {@code =>} kind of column/parameter:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3356
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3357
     *      <LI> functionColumnUnknown - nobody knows
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3358
     *      <LI> functionColumnIn - IN parameter
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3359
     *      <LI> functionColumnInOut - INOUT parameter
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3360
     *      <LI> functionColumnOut - OUT parameter
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3361
     *      <LI> functionColumnReturn - function return value
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3362
     *      <LI> functionColumnResult - Indicates that the parameter or column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3363
     *  is a column in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3364
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3365
     *  <LI><B>DATA_TYPE</B> int {@code =>} SQL type from java.sql.Types
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3366
     *  <LI><B>TYPE_NAME</B> String {@code =>} SQL type name, for a UDT type the
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3367
     *  type name is fully qualified
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3368
     *  <LI><B>PRECISION</B> int {@code =>} precision
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3369
     *  <LI><B>LENGTH</B> int {@code =>} length in bytes of data
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3370
     *  <LI><B>SCALE</B> short {@code =>} scale -  null is returned for data types where
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3371
     * SCALE is not applicable.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3372
     *  <LI><B>RADIX</B> short {@code =>} radix
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3373
     *  <LI><B>NULLABLE</B> short {@code =>} can it contain NULL.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3374
     *      <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3375
     *      <LI> functionNoNulls - does not allow NULL values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3376
     *      <LI> functionNullable - allows NULL values
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3377
     *      <LI> functionNullableUnknown - nullability unknown
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3378
     *      </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3379
     *  <LI><B>REMARKS</B> String {@code =>} comment describing column/parameter
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3380
     *  <LI><B>CHAR_OCTET_LENGTH</B> int  {@code =>} the maximum length of binary
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3381
     * and character based parameters or columns.  For any other datatype the returned value
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3382
     * is a NULL
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3383
     *  <LI><B>ORDINAL_POSITION</B> int  {@code =>} the ordinal position, starting
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3384
     * from 1, for the input and output parameters. A value of 0
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3385
     * is returned if this row describes the function's return value.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3386
     * For result set columns, it is the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3387
     * ordinal position of the column in the result set starting from 1.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3388
     *  <LI><B>IS_NULLABLE</B> String  {@code =>} ISO rules are used to determine
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3389
     * the nullability for a parameter or column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3390
     *       <UL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3391
     *       <LI> YES           --- if the parameter or column can include NULLs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3392
     *       <LI> NO            --- if the parameter or column  cannot include NULLs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3393
     *       <LI> empty string  --- if the nullability for the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3394
     * parameter  or column is unknown
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3395
     *       </UL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3396
     *  <LI><B>SPECIFIC_NAME</B> String  {@code =>} the name which uniquely identifies
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3397
     * this function within its schema.  This is a user specified, or DBMS
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3398
     * generated, name that may be different then the <code>FUNCTION_NAME</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3399
     * for example with overload functions
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3400
     *  </OL>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3401
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3402
     * <p>The PRECISION column represents the specified column size for the given
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3403
     * parameter or column.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3404
     * For numeric data, this is the maximum precision.  For character data, this is the length in characters.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3405
     * For datetime datatypes, this is the length in characters of the String representation (assuming the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3406
     * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3407
     * this is the length in bytes. Null is returned for data types where the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3408
     * column size is not applicable.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3409
     * @param catalog a catalog name; must match the catalog name as it
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3410
     *        is stored in the database; "" retrieves those without a catalog;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3411
     *        <code>null</code> means that the catalog name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3412
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3413
     * @param schemaPattern a schema name pattern; must match the schema name
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3414
     *        as it is stored in the database; "" retrieves those without a schema;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3415
     *        <code>null</code> means that the schema name should not be used to narrow
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3416
     *        the search
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3417
     * @param functionNamePattern a procedure name pattern; must match the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3418
     *        function name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3419
     * @param columnNamePattern a parameter name pattern; must match the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3420
     * parameter or column name as it is stored in the database
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3421
     * @return <code>ResultSet</code> - each row describes a
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3422
     * user function parameter, column  or return type
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3423
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3424
     * @exception SQLException if a database access error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3425
     * @see #getSearchStringEscape
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3426
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3427
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3428
    ResultSet getFunctionColumns(String catalog,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3429
                                  String schemaPattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3430
                                  String functionNamePattern,
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3431
                                  String columnNamePattern) throws SQLException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3432
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3433
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3434
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3435
     * Indicates that type of the parameter or column is unknown.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3436
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3437
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3438
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3439
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3440
     * returned by the method <code>getFunctionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3441
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3442
    int functionColumnUnknown = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3443
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3444
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3445
     * Indicates that the parameter or column is an IN parameter.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3446
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3447
     *  A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3448
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3449
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3450
     * returned by the method <code>getFunctionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3451
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3452
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3453
    int functionColumnIn = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3454
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3455
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3456
     * Indicates that the parameter or column is an INOUT parameter.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3457
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3458
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3459
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3460
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3461
     * returned by the method <code>getFunctionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3462
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3463
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3464
    int functionColumnInOut = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3465
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3466
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3467
     * Indicates that the parameter or column is an OUT parameter.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3468
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3469
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3470
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3471
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3472
     * returned by the method <code>getFunctionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3473
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3474
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3475
    int functionColumnOut = 3;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3476
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3477
     * Indicates that the parameter or column is a return value.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3478
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3479
     *  A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3480
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3481
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3482
     * returned by the method <code>getFunctionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3483
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3484
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3485
    int functionReturn = 4;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3486
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3487
       /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3488
     * Indicates that the parameter or column is a column in a result set.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3489
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3490
     *  A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3491
     * <code>COLUMN_TYPE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3492
     * in the <code>ResultSet</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3493
     * returned by the method <code>getFunctionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3494
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3495
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3496
    int functionColumnResult = 5;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3497
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3498
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3499
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3500
     * Indicates that <code>NULL</code> values are not allowed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3501
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3502
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3503
     * <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3504
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3505
     * returned by the method <code>getFunctionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3506
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3507
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3508
    int functionNoNulls = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3509
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3510
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3511
     * Indicates that <code>NULL</code> values are allowed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3512
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3513
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3514
     * <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3515
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3516
     * returned by the method <code>getFunctionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3517
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3518
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3519
    int functionNullable = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3520
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3521
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3522
     * Indicates that whether <code>NULL</code> values are allowed
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3523
     * is unknown.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3524
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3525
     * A possible value for the column
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3526
     * <code>NULLABLE</code>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3527
     * in the <code>ResultSet</code> object
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3528
     * returned by the method <code>getFunctionColumns</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3529
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3530
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3531
    int functionNullableUnknown = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3532
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3533
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3534
     * Indicates that it is not known whether the function returns
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3535
     * a result or a table.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3536
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3537
     * A possible value for column <code>FUNCTION_TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3538
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3539
     * <code>getFunctions</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3540
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3541
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3542
    int functionResultUnknown   = 0;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3543
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3544
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3545
     * Indicates that the function  does not return a table.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3546
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3547
     * A possible value for column <code>FUNCTION_TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3548
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3549
     * <code>getFunctions</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3550
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3551
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3552
    int functionNoTable         = 1;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3553
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3554
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3555
     * Indicates that the function  returns a table.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3556
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3557
     * A possible value for column <code>FUNCTION_TYPE</code> in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3558
     * <code>ResultSet</code> object returned by the method
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3559
     * <code>getFunctions</code>.
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3560
     * @since 1.6
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3561
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3562
    int functionReturnsTable    = 2;
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3563
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3564
    //--------------------------JDBC 4.1 -----------------------------
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3565
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3566
    /**
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3567
     * Retrieves a description of the pseudo or hidden columns available
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3568
     * in a given table within the specified catalog and schema.
6541
a40c440705b3 6983984: Fixed typo in DatabaseMetaData.getPseudoColumns() javadocs
lancea
parents: 6540
diff changeset
  3569
     * Pseudo or hidden columns may not always be stored within
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3570
     * a table and are not visible in a ResultSet unless they are
6541
a40c440705b3 6983984: Fixed typo in DatabaseMetaData.getPseudoColumns() javadocs
lancea
parents: 6540
diff changeset
  3571
     * specified in the query's outermost SELECT list. Pseudo or hidden
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3572
     * columns may not necessarily be able to be modified. If there are
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3573
     * no pseudo or hidden columns, an empty ResultSet is returned.
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3574
     *
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3575
     * <P>Only column descriptions matching the catalog, schema, table
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3576
     * and column name criteria are returned.  They are ordered by
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3577
     * <code>TABLE_CAT</code>,<code>TABLE_SCHEM</code>, <code>TABLE_NAME</code>
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3578
     * and <code>COLUMN_NAME</code>.
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3579
     *
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3580
     * <P>Each column description has the following columns:
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3581
     *  <OL>
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3582
     *  <LI><B>TABLE_CAT</B> String {@code =>} table catalog (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3583
     *  <LI><B>TABLE_SCHEM</B> String {@code =>} table schema (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3584
     *  <LI><B>TABLE_NAME</B> String {@code =>} table name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3585
     *  <LI><B>COLUMN_NAME</B> String {@code =>} column name
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3586
     *  <LI><B>DATA_TYPE</B> int {@code =>} SQL type from java.sql.Types
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3587
     *  <LI><B>COLUMN_SIZE</B> int {@code =>} column size.
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3588
     *  <LI><B>DECIMAL_DIGITS</B> int {@code =>} the number of fractional digits. Null is returned for data types where
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3589
     * DECIMAL_DIGITS is not applicable.
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3590
     *  <LI><B>NUM_PREC_RADIX</B> int {@code =>} Radix (typically either 10 or 2)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3591
     *  <LI><B>COLUMN_USAGE</B> String {@code =>} The allowed usage for the column.  The
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3592
     *  value returned will correspond to the enum name returned by {@link PseudoColumnUsage#name PseudoColumnUsage.name()}
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3593
     *  <LI><B>REMARKS</B> String {@code =>} comment describing column (may be <code>null</code>)
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3594
     *  <LI><B>CHAR_OCTET_LENGTH</B> int {@code =>} for char types the
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3595
     *       maximum number of bytes in the column
18156
edb590d448c5 8016217: More javadoc warnings
alanb
parents: 15278
diff changeset
  3596
     *  <LI><B>IS_NULLABLE</B> String  {@code =>} ISO rules are used to determine the nullability for a column.
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3597
     *       <UL>
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3598
     *       <LI> YES           --- if the column can include NULLs
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3599
     *       <LI> NO            --- if the column cannot include NULLs
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3600
     *       <LI> empty string  --- if the nullability for the column is unknown
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3601
     *       </UL>
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3602
     *  </OL>
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3603
     *
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3604
     * <p>The COLUMN_SIZE column specifies the column size for the given column.
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3605
     * For numeric data, this is the maximum precision.  For character data, this is the length in characters.
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3606
     * For datetime datatypes, this is the length in characters of the String representation (assuming the
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3607
     * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype,
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3608
     * this is the length in bytes. Null is returned for data types where the
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3609
     * column size is not applicable.
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3610
     *
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3611
     * @param catalog a catalog name; must match the catalog name as it
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3612
     *        is stored in the database; "" retrieves those without a catalog;
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3613
     *        <code>null</code> means that the catalog name should not be used to narrow
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3614
     *        the search
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3615
     * @param schemaPattern a schema name pattern; must match the schema name
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3616
     *        as it is stored in the database; "" retrieves those without a schema;
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3617
     *        <code>null</code> means that the schema name should not be used to narrow
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3618
     *        the search
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3619
     * @param tableNamePattern a table name pattern; must match the
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3620
     *        table name as it is stored in the database
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3621
     * @param columnNamePattern a column name pattern; must match the column
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3622
     *        name as it is stored in the database
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3623
     * @return <code>ResultSet</code> - each row is a column description
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3624
     * @exception SQLException if a database access error occurs
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3625
     * @see PseudoColumnUsage
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3626
     * @since 1.7
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3627
     */
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3628
    ResultSet getPseudoColumns(String catalog, String schemaPattern,
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3629
                         String tableNamePattern, String columnNamePattern)
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3630
        throws SQLException;
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3631
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3632
    /**
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3633
     * Retrieves whether a generated key will always be returned if the column
6666
80571aeec9b0 6985400: DatabaseMetaData.generatedKeyAlwaysReturned, "indexe(s)" should be "index(es)"
lancea
parents: 6541
diff changeset
  3634
     * name(s) or index(es) specified for the auto generated key column(s)
6540
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3635
     * are valid and the statement succeeds.  The key that is returned may or
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3636
     * may not be based on the column(s) for the auto generated key.
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3637
     * Consult your JDBC driver documentation for additional details.
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3638
     * @return <code>true</code> if so; <code>false</code> otherwise
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3639
     * @exception SQLException if a database access error occurs
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3640
     * @since 1.7
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3641
     */
a4ae668f6125 6589685: JDBC 4.1 updates
lancea
parents: 5506
diff changeset
  3642
    boolean  generatedKeyAlwaysReturned() throws SQLException;
15278
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3643
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3644
    //--------------------------JDBC 4.2 -----------------------------
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3645
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3646
    /**
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3647
     *
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3648
     * Retrieves the maximum number of bytes this database allows for
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3649
     * the logical size for a {@code LOB}.
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3650
     *<p>
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3651
     * The default implementation will return {@code 0}
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3652
     *
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3653
     * @return the maximum number of bytes allowed; a result of zero
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3654
     * means that there is no limit or the limit is not known
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3655
     * @exception SQLException if a database access error occurs
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3656
     * @since 1.8
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3657
     */
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3658
    default long getMaxLogicalLobSize() throws SQLException {
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3659
        return 0;
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3660
    }
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3661
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3662
    /**
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3663
     * Retrieves whether this database supports REF CURSOR.
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3664
     *<p>
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3665
     * The default implementation will return {@code false}
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3666
     *
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3667
     * @return {@code true} if this database supports REF CURSOR;
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3668
     *         {@code false} otherwise
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3669
     * @exception SQLException if a database access error occurs
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3670
     * @since 1.8
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3671
     */
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3672
    default boolean supportsRefCursors() throws SQLException{
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3673
        return false;
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3674
    }
e081d3f73b75 8005080: JDBC 4.2 Core changes
lancea
parents: 6666
diff changeset
  3675
34338
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3676
    // JDBC 4.3
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3677
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3678
    /**
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3679
     * Retrieves whether this database supports sharding.
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3680
     * @implSpec
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3681
     * The default implementation will return {@code false}
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3682
     *
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3683
     * @return {@code true} if this database supports sharding;
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3684
     *         {@code false} otherwise
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3685
     * @exception SQLException if a database access error occurs
35302
e4d2275861c3 8136494: Update "@since 1.9" to "@since 9" to match java.version.specification
iris
parents: 34338
diff changeset
  3686
     * @since 9
34338
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3687
     */
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3688
    default boolean supportsSharding() throws SQLException {
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3689
        return false;
67d0e5867568 8085984: Add JDBC Sharding API
lancea
parents: 25991
diff changeset
  3690
    }
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
  3691
}