Source Code Cross Referenced for DatabaseMetaData.java in  » 6.0-JDK-Core » sql » java » sql » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Home
Java Source Code / Java Documentation
1.6.0 JDK Core
2.6.0 JDK Modules
3.6.0 JDK Modules com.sun
4.6.0 JDK Modules com.sun.java
5.6.0 JDK Modules sun
6.6.0 JDK Platform
7.Ajax
8.Apache Harmony Java SE
9.Aspect oriented
10.Authentication Authorization
11.Blogger System
12.Build
13.Byte Code
14.Cache
15.Chart
16.Chat
17.Code Analyzer
18.Collaboration
19.Content Management System
20.Database Client
21.Database DBMS
22.Database JDBC Connection Pool
23.Database ORM
24.Development
25.EJB Server
26.ERP CRM Financial
27.ESB
28.Forum
29.Game
30.GIS
31.Graphic 3D
32.Graphic Library
33.Groupware
34.HTML Parser
35.IDE
36.IDE Eclipse
37.IDE Netbeans
38.Installer
39.Internationalization Localization
40.Inversion of Control
41.Issue Tracking
42.J2EE
43.J2ME
44.JBoss
45.JMS
46.JMX
47.Library
48.Mail Clients
49.Music
50.Net
51.Parser
52.PDF
53.Portal
54.Profiler
55.Project Management
56.Report
57.RSS RDF
58.Rule Engine
59.Science
60.Scripting
61.Search Engine
62.Security
63.Sevlet Container
64.Source Control
65.Swing Library
66.Template Engine
67.Test Coverage
68.Testing
69.UML
70.Web Crawler
71.Web Framework
72.Web Mail
73.Web Server
74.Web Services
75.Web Services apache cxf 2.2.6
76.Web Services AXIS2
77.Wiki Engine
78.Workflow Engines
79.XML
80.XML UI
Java Source Code / Java Documentation » 6.0 JDK Core » sql » java.sql 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


0001        /*
0002         * Copyright 1996-2006 Sun Microsystems, Inc.  All Rights Reserved.
0003         * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
0004         *
0005         * This code is free software; you can redistribute it and/or modify it
0006         * under the terms of the GNU General Public License version 2 only, as
0007         * published by the Free Software Foundation.  Sun designates this
0008         * particular file as subject to the "Classpath" exception as provided
0009         * by Sun in the LICENSE file that accompanied this code.
0010         *
0011         * This code is distributed in the hope that it will be useful, but WITHOUT
0012         * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
0013         * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
0014         * version 2 for more details (a copy is included in the LICENSE file that
0015         * accompanied this code).
0016         *
0017         * You should have received a copy of the GNU General Public License version
0018         * 2 along with this work; if not, write to the Free Software Foundation,
0019         * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
0020         *
0021         * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
0022         * CA 95054 USA or visit www.sun.com if you need additional information or
0023         * have any questions.
0024         */
0025
0026        package java.sql;
0027
0028        /**
0029         * Comprehensive information about the database as a whole.
0030         * <P>
0031         * This interface is implemented by driver vendors to let users know the capabilities
0032         * of a Database Management System (DBMS) in combination with 
0033         * the driver based on JDBC<sup><font size=-2>TM</font></sup> technology 
0034         * ("JDBC driver") that is used with it.  Different relational DBMSs often support
0035         * different features, implement features in different ways, and use different
0036         * data types.  In addition, a driver may implement a feature on top of what the 
0037         * DBMS offers.  Information returned by methods in this interface applies
0038         * to the capabilities of a particular driver and a particular DBMS working
0039         * together. Note that as used in this documentation, the term "database" is
0040         * used generically to refer to both the driver and DBMS.
0041         * <P>
0042         * A user for this interface is commonly a tool that needs to discover how to
0043         * deal with the underlying DBMS.  This is especially true for applications
0044         * that are intended to be used with more than one DBMS. For example, a tool might use the method 
0045         * <code>getTypeInfo</code> to find out what data types can be used in a
0046         * <code>CREATE TABLE</code> statement.  Or a user might call the method
0047         * <code>supportsCorrelatedSubqueries</code> to see if it is possible to use
0048         * a correlated subquery or <code>supportsBatchUpdates</code> to see if it is 
0049         * possible to use batch updates. 
0050         * <P>
0051         * Some <code>DatabaseMetaData</code> methods return lists of information
0052         * in the form of <code>ResultSet</code> objects.
0053         * Regular <code>ResultSet</code> methods, such as
0054         * <code>getString</code> and <code>getInt</code>, can be used 
0055         * to retrieve the data from these <code>ResultSet</code> objects.  If 
0056         * a given form of metadata is not available, an empty <code>ResultSet</code>
0057         * will be returned. Additional columns beyond the columns defined to be 
0058         * returned by the <code>ResultSet</code> object for a given method 
0059         * can be defined by the JDBC driver vendor and must be accessed 
0060         * by their <B>column label</B>.
0061         * <P>
0062         * Some <code>DatabaseMetaData</code> methods take arguments that are 
0063         * String patterns.  These arguments all have names such as fooPattern.  
0064         * Within a pattern String, "%" means match any substring of 0 or more 
0065         * characters, and "_" means match any one character. Only metadata 
0066         * entries matching the search pattern are returned. If a search pattern 
0067         * argument is set to <code>null</code>, that argument's criterion will 
0068         * be dropped from the search.
0069         * <P>
0070         */
0071        public interface DatabaseMetaData extends Wrapper {
0072
0073            //----------------------------------------------------------------------
0074            // First, a variety of minor information about the target database.
0075
0076            /**
0077             * Retrieves whether the current user can call all the procedures 
0078             * returned by the method <code>getProcedures</code>.
0079             *
0080             * @return <code>true</code> if so; <code>false</code> otherwise
0081             * @exception SQLException if a database access error occurs
0082             */
0083            boolean allProceduresAreCallable() throws SQLException;
0084
0085            /**
0086             * Retrieves whether the current user can use all the tables returned 
0087             * by the method <code>getTables</code> in a <code>SELECT</code> 
0088             * statement.
0089             *
0090             * @return <code>true</code> if so; <code>false</code> otherwise 
0091             * @exception SQLException if a database access error occurs
0092             */
0093            boolean allTablesAreSelectable() throws SQLException;
0094
0095            /**
0096             * Retrieves the URL for this DBMS.
0097             *
0098             * @return the URL for this DBMS or <code>null</code> if it cannot be 
0099             *          generated
0100             * @exception SQLException if a database access error occurs
0101             */
0102            String getURL() throws SQLException;
0103
0104            /**
0105             * Retrieves the user name as known to this database.
0106             *
0107             * @return the database user name
0108             * @exception SQLException if a database access error occurs
0109             */
0110            String getUserName() throws SQLException;
0111
0112            /**
0113             * Retrieves whether this database is in read-only mode.
0114             *
0115             * @return <code>true</code> if so; <code>false</code> otherwise
0116             * @exception SQLException if a database access error occurs
0117             */
0118            boolean isReadOnly() throws SQLException;
0119
0120            /**
0121             * Retrieves whether <code>NULL</code> values are sorted high.
0122             * Sorted high means that <code>NULL</code> values
0123             * sort higher than any other value in a domain.  In an ascending order,
0124             * if this method returns <code>true</code>,  <code>NULL</code> values
0125             * will appear at the end. By contrast, the method 
0126             * <code>nullsAreSortedAtEnd</code> indicates whether <code>NULL</code> values
0127             * are sorted at the end regardless of sort order.
0128             *
0129             * @return <code>true</code> if so; <code>false</code> otherwise
0130             * @exception SQLException if a database access error occurs
0131             */
0132            boolean nullsAreSortedHigh() throws SQLException;
0133
0134            /**
0135             * Retrieves whether <code>NULL</code> values are sorted low.
0136             * Sorted low means that <code>NULL</code> values
0137             * sort lower than any other value in a domain.  In an ascending order,
0138             * if this method returns <code>true</code>,  <code>NULL</code> values
0139             * will appear at the beginning. By contrast, the method 
0140             * <code>nullsAreSortedAtStart</code> indicates whether <code>NULL</code> values
0141             * are sorted at the beginning regardless of sort order.
0142             *
0143             * @return <code>true</code> if so; <code>false</code> otherwise
0144             * @exception SQLException if a database access error occurs
0145             */
0146            boolean nullsAreSortedLow() throws SQLException;
0147
0148            /**
0149             * Retrieves whether <code>NULL</code> values are sorted at the start regardless 
0150             * of sort order.
0151             *
0152             * @return <code>true</code> if so; <code>false</code> otherwise 
0153             * @exception SQLException if a database access error occurs
0154             */
0155            boolean nullsAreSortedAtStart() throws SQLException;
0156
0157            /**
0158             * Retrieves whether <code>NULL</code> values are sorted at the end regardless of 
0159             * sort order.
0160             *
0161             * @return <code>true</code> if so; <code>false</code> otherwise
0162             * @exception SQLException if a database access error occurs
0163             */
0164            boolean nullsAreSortedAtEnd() throws SQLException;
0165
0166            /**
0167             * Retrieves the name of this database product.
0168             *
0169             * @return database product name
0170             * @exception SQLException if a database access error occurs
0171             */
0172            String getDatabaseProductName() throws SQLException;
0173
0174            /**
0175             * Retrieves the version number of this database product.
0176             *
0177             * @return database version number
0178             * @exception SQLException if a database access error occurs
0179             */
0180            String getDatabaseProductVersion() throws SQLException;
0181
0182            /**
0183             * Retrieves the name of this JDBC driver.
0184             *
0185             * @return JDBC driver name
0186             * @exception SQLException if a database access error occurs
0187             */
0188            String getDriverName() throws SQLException;
0189
0190            /**
0191             * Retrieves the version number of this JDBC driver as a <code>String</code>.
0192             *
0193             * @return JDBC driver version
0194             * @exception SQLException if a database access error occurs
0195             */
0196            String getDriverVersion() throws SQLException;
0197
0198            /**
0199             * Retrieves this JDBC driver's major version number.
0200             *
0201             * @return JDBC driver major version
0202             */
0203            int getDriverMajorVersion();
0204
0205            /**
0206             * Retrieves this JDBC driver's minor version number.
0207             *
0208             * @return JDBC driver minor version number
0209             */
0210            int getDriverMinorVersion();
0211
0212            /**
0213             * Retrieves whether this database stores tables in a local file.
0214             *
0215             * @return <code>true</code> if so; <code>false</code> otherwise
0216             * @exception SQLException if a database access error occurs
0217             */
0218            boolean usesLocalFiles() throws SQLException;
0219
0220            /**
0221             * Retrieves whether this database uses a file for each table.
0222             *
0223             * @return <code>true</code> if this database uses a local file for each table;
0224             *         <code>false</code> otherwise
0225             * @exception SQLException if a database access error occurs
0226             */
0227            boolean usesLocalFilePerTable() throws SQLException;
0228
0229            /**
0230             * Retrieves whether this database treats mixed case unquoted SQL identifiers as
0231             * case sensitive and as a result stores them in mixed case.
0232             *
0233             * @return <code>true</code> if so; <code>false</code> otherwise 
0234             * @exception SQLException if a database access error occurs
0235             */
0236            boolean supportsMixedCaseIdentifiers() throws SQLException;
0237
0238            /**
0239             * Retrieves whether this database treats mixed case unquoted SQL identifiers as
0240             * case insensitive and stores them in upper case.
0241             *
0242             * @return <code>true</code> if so; <code>false</code> otherwise 
0243             * @exception SQLException if a database access error occurs
0244             */
0245            boolean storesUpperCaseIdentifiers() throws SQLException;
0246
0247            /**
0248             * Retrieves whether this database treats mixed case unquoted SQL identifiers as
0249             * case insensitive and stores them in lower case.
0250             *
0251             * @return <code>true</code> if so; <code>false</code> otherwise 
0252             * @exception SQLException if a database access error occurs
0253             */
0254            boolean storesLowerCaseIdentifiers() throws SQLException;
0255
0256            /**
0257             * Retrieves whether this database treats mixed case unquoted SQL identifiers as
0258             * case insensitive and stores them in mixed case.
0259             *
0260             * @return <code>true</code> if so; <code>false</code> otherwise 
0261             * @exception SQLException if a database access error occurs
0262             */
0263            boolean storesMixedCaseIdentifiers() throws SQLException;
0264
0265            /**
0266             * Retrieves whether this database treats mixed case quoted SQL identifiers as
0267             * case sensitive and as a result stores them in mixed case.
0268             *
0269             * @return <code>true</code> if so; <code>false</code> otherwise
0270             * @exception SQLException if a database access error occurs
0271             */
0272            boolean supportsMixedCaseQuotedIdentifiers() throws SQLException;
0273
0274            /**
0275             * Retrieves whether this database treats mixed case quoted SQL identifiers as
0276             * case insensitive and stores them in upper case.
0277             *
0278             * @return <code>true</code> if so; <code>false</code> otherwise 
0279             * @exception SQLException if a database access error occurs
0280             */
0281            boolean storesUpperCaseQuotedIdentifiers() throws SQLException;
0282
0283            /**
0284             * Retrieves whether this database treats mixed case quoted SQL identifiers as
0285             * case insensitive and stores them in lower case.
0286             *
0287             * @return <code>true</code> if so; <code>false</code> otherwise 
0288             * @exception SQLException if a database access error occurs
0289             */
0290            boolean storesLowerCaseQuotedIdentifiers() throws SQLException;
0291
0292            /**
0293             * Retrieves whether this database treats mixed case quoted SQL identifiers as
0294             * case insensitive and stores them in mixed case.
0295             *
0296             * @return <code>true</code> if so; <code>false</code> otherwise 
0297             * @exception SQLException if a database access error occurs
0298             */
0299            boolean storesMixedCaseQuotedIdentifiers() throws SQLException;
0300
0301            /**
0302             * Retrieves the string used to quote SQL identifiers.
0303             * This method returns a space " " if identifier quoting is not supported.
0304             *
0305             * @return the quoting string or a space if quoting is not supported
0306             * @exception SQLException if a database access error occurs
0307             */
0308            String getIdentifierQuoteString() throws SQLException;
0309
0310            /**
0311             * Retrieves a comma-separated list of all of this database's SQL keywords
0312             * that are NOT also SQL:2003 keywords.
0313             *
0314             * @return the list of this database's keywords that are not also
0315             *         SQL:2003 keywords
0316             * @exception SQLException if a database access error occurs
0317             */
0318            String getSQLKeywords() throws SQLException;
0319
0320            /**
0321             * Retrieves a comma-separated list of math functions available with
0322             * this database.  These are the Open /Open CLI math function names used in 
0323             * the JDBC function escape clause.
0324             *
0325             * @return the list of math functions supported by this database
0326             * @exception SQLException if a database access error occurs
0327             */
0328            String getNumericFunctions() throws SQLException;
0329
0330            /**
0331             * Retrieves a comma-separated list of string functions available with
0332             * this database.  These are the  Open Group CLI string function names used 
0333             * in the JDBC function escape clause.
0334             *
0335             * @return the list of string functions supported by this database 
0336             * @exception SQLException if a database access error occurs
0337             */
0338            String getStringFunctions() throws SQLException;
0339
0340            /**
0341             * Retrieves a comma-separated list of system functions available with
0342             * this database.  These are the  Open Group CLI system function names used 
0343             * in the JDBC function escape clause.
0344             *
0345             * @return a list of system functions supported by this database
0346             * @exception SQLException if a database access error occurs
0347             */
0348            String getSystemFunctions() throws SQLException;
0349
0350            /**
0351             * Retrieves a comma-separated list of the time and date functions available 
0352             * with this database.
0353             *
0354             * @return the list of time and date functions supported by this database
0355             * @exception SQLException if a database access error occurs
0356             */
0357            String getTimeDateFunctions() throws SQLException;
0358
0359            /**
0360             * Retrieves the string that can be used to escape wildcard characters.
0361             * This is the string that can be used to escape '_' or '%' in
0362             * the catalog search parameters that are a pattern (and therefore use one
0363             * of the wildcard characters).
0364             *
0365             * <P>The '_' character represents any single character;
0366             * the '%' character represents any sequence of zero or 
0367             * more characters.
0368             *
0369             * @return the string used to escape wildcard characters
0370             * @exception SQLException if a database access error occurs
0371             */
0372            String getSearchStringEscape() throws SQLException;
0373
0374            /**
0375             * Retrieves all the "extra" characters that can be used in unquoted
0376             * identifier names (those beyond a-z, A-Z, 0-9 and _).
0377             *
0378             * @return the string containing the extra characters 
0379             * @exception SQLException if a database access error occurs
0380             */
0381            String getExtraNameCharacters() throws SQLException;
0382
0383            //--------------------------------------------------------------------
0384            // Functions describing which features are supported.
0385
0386            /**
0387             * Retrieves whether this database supports <code>ALTER TABLE</code>
0388             * with add column.
0389             *
0390             * @return <code>true</code> if so; <code>false</code> otherwise
0391             * @exception SQLException if a database access error occurs
0392             */
0393            boolean supportsAlterTableWithAddColumn() throws SQLException;
0394
0395            /**
0396             * Retrieves whether this database supports <code>ALTER TABLE</code>
0397             * with drop column.
0398             *
0399             * @return <code>true</code> if so; <code>false</code> otherwise
0400             * @exception SQLException if a database access error occurs
0401             */
0402            boolean supportsAlterTableWithDropColumn() throws SQLException;
0403
0404            /**
0405             * Retrieves whether this database supports column aliasing.
0406             *
0407             * <P>If so, the SQL AS clause can be used to provide names for
0408             * computed columns or to provide alias names for columns as
0409             * required.
0410             *
0411             * @return <code>true</code> if so; <code>false</code> otherwise 
0412             * @exception SQLException if a database access error occurs
0413             */
0414            boolean supportsColumnAliasing() throws SQLException;
0415
0416            /**
0417             * Retrieves whether this database supports concatenations between 
0418             * <code>NULL</code> and non-<code>NULL</code> values being 
0419             * <code>NULL</code>.
0420             *
0421             * @return <code>true</code> if so; <code>false</code> otherwise
0422             * @exception SQLException if a database access error occurs
0423             */
0424            boolean nullPlusNonNullIsNull() throws SQLException;
0425
0426            /**
0427             * Retrieves whether this database supports the JDBC scalar function 
0428             * <code>CONVERT</code> for the conversion of one JDBC type to another.
0429             * The JDBC types are the generic SQL data types defined 
0430             * in <code>java.sql.Types</code>.
0431             *
0432             * @return <code>true</code> if so; <code>false</code> otherwise
0433             * @exception SQLException if a database access error occurs
0434             */
0435            boolean supportsConvert() throws SQLException;
0436
0437            /**
0438             * Retrieves whether this database supports the JDBC scalar function 
0439             * <code>CONVERT</code> for conversions between the JDBC types <i>fromType</i>
0440             * and <i>toType</i>.  The JDBC types are the generic SQL data types defined 
0441             * in <code>java.sql.Types</code>.
0442             *
0443             * @param fromType the type to convert from; one of the type codes from
0444             *        the class <code>java.sql.Types</code>
0445             * @param toType the type to convert to; one of the type codes from 
0446             *        the class <code>java.sql.Types</code>
0447             * @return <code>true</code> if so; <code>false</code> otherwise
0448             * @exception SQLException if a database access error occurs
0449             * @see Types
0450             */
0451            boolean supportsConvert(int fromType, int toType)
0452                    throws SQLException;
0453
0454            /**
0455             * Retrieves whether this database supports table correlation names.
0456             *
0457             * @return <code>true</code> if so; <code>false</code> otherwise
0458             * @exception SQLException if a database access error occurs
0459             */
0460            boolean supportsTableCorrelationNames() throws SQLException;
0461
0462            /**
0463             * Retrieves whether, when table correlation names are supported, they 
0464             * are restricted to being different from the names of the tables.
0465             *
0466             * @return <code>true</code> if so; <code>false</code> otherwise 
0467             * @exception SQLException if a database access error occurs
0468             */
0469            boolean supportsDifferentTableCorrelationNames()
0470                    throws SQLException;
0471
0472            /**
0473             * Retrieves whether this database supports expressions in 
0474             * <code>ORDER BY</code> lists.
0475             *
0476             * @return <code>true</code> if so; <code>false</code> otherwise
0477             * @exception SQLException if a database access error occurs
0478             */
0479            boolean supportsExpressionsInOrderBy() throws SQLException;
0480
0481            /**
0482             * Retrieves whether this database supports using a column that is
0483             * not in the <code>SELECT</code> statement in an
0484             * <code>ORDER BY</code> clause.
0485             *
0486             * @return <code>true</code> if so; <code>false</code> otherwise
0487             * @exception SQLException if a database access error occurs
0488             */
0489            boolean supportsOrderByUnrelated() throws SQLException;
0490
0491            /**
0492             * Retrieves whether this database supports some form of 
0493             * <code>GROUP BY</code> clause.
0494             *
0495             * @return <code>true</code> if so; <code>false</code> otherwise
0496             * @exception SQLException if a database access error occurs
0497             */
0498            boolean supportsGroupBy() throws SQLException;
0499
0500            /**
0501             * Retrieves whether this database supports using a column that is
0502             * not in the <code>SELECT</code> statement in a
0503             * <code>GROUP BY</code> clause.
0504             *
0505             * @return <code>true</code> if so; <code>false</code> otherwise
0506             * @exception SQLException if a database access error occurs
0507             */
0508            boolean supportsGroupByUnrelated() throws SQLException;
0509
0510            /**
0511             * Retrieves whether this database supports using columns not included in
0512             * the <code>SELECT</code> statement in a <code>GROUP BY</code> clause 
0513             * provided that all of the columns in the <code>SELECT</code> statement
0514             * are included in the <code>GROUP BY</code> clause.
0515             *
0516             * @return <code>true</code> if so; <code>false</code> otherwise
0517             * @exception SQLException if a database access error occurs
0518             */
0519            boolean supportsGroupByBeyondSelect() throws SQLException;
0520
0521            /**
0522             * Retrieves whether this database supports specifying a
0523             * <code>LIKE</code> escape clause.
0524             *
0525             * @return <code>true</code> if so; <code>false</code> otherwise
0526             * @exception SQLException if a database access error occurs
0527             */
0528            boolean supportsLikeEscapeClause() throws SQLException;
0529
0530            /**
0531             * Retrieves whether this database supports getting multiple 
0532             * <code>ResultSet</code> objects from a single call to the
0533             * method <code>execute</code>.
0534             *
0535             * @return <code>true</code> if so; <code>false</code> otherwise
0536             * @exception SQLException if a database access error occurs
0537             */
0538            boolean supportsMultipleResultSets() throws SQLException;
0539
0540            /**
0541             * Retrieves whether this database allows having multiple 
0542             * transactions open at once (on different connections).
0543             *
0544             * @return <code>true</code> if so; <code>false</code> otherwise
0545             * @exception SQLException if a database access error occurs
0546             */
0547            boolean supportsMultipleTransactions() throws SQLException;
0548
0549            /**
0550             * Retrieves whether columns in this database may be defined as non-nullable.
0551             *
0552             * @return <code>true</code> if so; <code>false</code> otherwise
0553             * @exception SQLException if a database access error occurs
0554             */
0555            boolean supportsNonNullableColumns() throws SQLException;
0556
0557            /**
0558             * Retrieves whether this database supports the ODBC Minimum SQL grammar.
0559             *
0560             * @return <code>true</code> if so; <code>false</code> otherwise
0561             * @exception SQLException if a database access error occurs
0562             */
0563            boolean supportsMinimumSQLGrammar() throws SQLException;
0564
0565            /**
0566             * Retrieves whether this database supports the ODBC Core SQL grammar.
0567             *
0568             * @return <code>true</code> if so; <code>false</code> otherwise
0569             * @exception SQLException if a database access error occurs
0570             */
0571            boolean supportsCoreSQLGrammar() throws SQLException;
0572
0573            /**
0574             * Retrieves whether this database supports the ODBC Extended SQL grammar.
0575             *
0576             * @return <code>true</code> if so; <code>false</code> otherwise
0577             * @exception SQLException if a database access error occurs
0578             */
0579            boolean supportsExtendedSQLGrammar() throws SQLException;
0580
0581            /**
0582             * Retrieves whether this database supports the ANSI92 entry level SQL 
0583             * grammar.
0584             *
0585             * @return <code>true</code> if so; <code>false</code> otherwise
0586             * @exception SQLException if a database access error occurs
0587             */
0588            boolean supportsANSI92EntryLevelSQL() throws SQLException;
0589
0590            /**
0591             * Retrieves whether this database supports the ANSI92 intermediate SQL grammar supported.
0592             *
0593             * @return <code>true</code> if so; <code>false</code> otherwise
0594             * @exception SQLException if a database access error occurs
0595             */
0596            boolean supportsANSI92IntermediateSQL() throws SQLException;
0597
0598            /**
0599             * Retrieves whether this database supports the ANSI92 full SQL grammar supported.
0600             *
0601             * @return <code>true</code> if so; <code>false</code> otherwise
0602             * @exception SQLException if a database access error occurs
0603             */
0604            boolean supportsANSI92FullSQL() throws SQLException;
0605
0606            /**
0607             * Retrieves whether this database supports the SQL Integrity 
0608             * Enhancement Facility.
0609             *
0610             * @return <code>true</code> if so; <code>false</code> otherwise
0611             * @exception SQLException if a database access error occurs
0612             */
0613            boolean supportsIntegrityEnhancementFacility() throws SQLException;
0614
0615            /**
0616             * Retrieves whether this database supports some form of outer join.
0617             *
0618             * @return <code>true</code> if so; <code>false</code> otherwise
0619             * @exception SQLException if a database access error occurs
0620             */
0621            boolean supportsOuterJoins() throws SQLException;
0622
0623            /**
0624             * Retrieves whether this database supports full nested outer joins.
0625             *
0626             * @return <code>true</code> if so; <code>false</code> otherwise
0627             * @exception SQLException if a database access error occurs
0628             */
0629            boolean supportsFullOuterJoins() throws SQLException;
0630
0631            /**
0632             * Retrieves whether this database provides limited support for outer 
0633             * joins.  (This will be <code>true</code> if the method 
0634             * <code>supportsFullOuterJoins</code> returns <code>true</code>).
0635             *
0636             * @return <code>true</code> if so; <code>false</code> otherwise
0637             * @exception SQLException if a database access error occurs
0638             */
0639            boolean supportsLimitedOuterJoins() throws SQLException;
0640
0641            /**
0642             * Retrieves the database vendor's preferred term for "schema".
0643             *
0644             * @return the vendor term for "schema"
0645             * @exception SQLException if a database access error occurs
0646             */
0647            String getSchemaTerm() throws SQLException;
0648
0649            /**
0650             * Retrieves the database vendor's preferred term for "procedure".
0651             *
0652             * @return the vendor term for "procedure"
0653             * @exception SQLException if a database access error occurs
0654             */
0655            String getProcedureTerm() throws SQLException;
0656
0657            /**
0658             * Retrieves the database vendor's preferred term for "catalog".
0659             *
0660             * @return the vendor term for "catalog"
0661             * @exception SQLException if a database access error occurs
0662             */
0663            String getCatalogTerm() throws SQLException;
0664
0665            /**
0666             * Retrieves whether a catalog appears at the start of a fully qualified 
0667             * table name.  If not, the catalog appears at the end.
0668             *
0669             * @return <code>true</code> if the catalog name appears at the beginning
0670             *         of a fully qualified table name; <code>false</code> otherwise 
0671             * @exception SQLException if a database access error occurs
0672             */
0673            boolean isCatalogAtStart() throws SQLException;
0674
0675            /**
0676             * Retrieves the <code>String</code> that this database uses as the 
0677             * separator between a catalog and table name.
0678             *
0679             * @return the separator string
0680             * @exception SQLException if a database access error occurs
0681             */
0682            String getCatalogSeparator() throws SQLException;
0683
0684            /**
0685             * Retrieves whether a schema name can be used in a data manipulation statement.
0686             *
0687             * @return <code>true</code> if so; <code>false</code> otherwise
0688             * @exception SQLException if a database access error occurs
0689             */
0690            boolean supportsSchemasInDataManipulation() throws SQLException;
0691
0692            /**
0693             * Retrieves whether a schema name can be used in a procedure call statement.
0694             *
0695             * @return <code>true</code> if so; <code>false</code> otherwise
0696             * @exception SQLException if a database access error occurs
0697             */
0698            boolean supportsSchemasInProcedureCalls() throws SQLException;
0699
0700            /**
0701             * Retrieves whether a schema name can be used in a table definition statement.
0702             *
0703             * @return <code>true</code> if so; <code>false</code> otherwise
0704             * @exception SQLException if a database access error occurs
0705             */
0706            boolean supportsSchemasInTableDefinitions() throws SQLException;
0707
0708            /**
0709             * Retrieves whether a schema name can be used in an index definition statement.
0710             *
0711             * @return <code>true</code> if so; <code>false</code> otherwise
0712             * @exception SQLException if a database access error occurs
0713             */
0714            boolean supportsSchemasInIndexDefinitions() throws SQLException;
0715
0716            /**
0717             * Retrieves whether a schema name can be used in a privilege definition statement.
0718             *
0719             * @return <code>true</code> if so; <code>false</code> otherwise
0720             * @exception SQLException if a database access error occurs
0721             */
0722            boolean supportsSchemasInPrivilegeDefinitions() throws SQLException;
0723
0724            /**
0725             * Retrieves whether a catalog name can be used in a data manipulation statement.
0726             *
0727             * @return <code>true</code> if so; <code>false</code> otherwise
0728             * @exception SQLException if a database access error occurs
0729             */
0730            boolean supportsCatalogsInDataManipulation() throws SQLException;
0731
0732            /**
0733             * Retrieves whether a catalog name can be used in a procedure call statement.
0734             *
0735             * @return <code>true</code> if so; <code>false</code> otherwise
0736             * @exception SQLException if a database access error occurs
0737             */
0738            boolean supportsCatalogsInProcedureCalls() throws SQLException;
0739
0740            /**
0741             * Retrieves whether a catalog name can be used in a table definition statement.
0742             *
0743             * @return <code>true</code> if so; <code>false</code> otherwise
0744             * @exception SQLException if a database access error occurs
0745             */
0746            boolean supportsCatalogsInTableDefinitions() throws SQLException;
0747
0748            /**
0749             * Retrieves whether a catalog name can be used in an index definition statement.
0750             *
0751             * @return <code>true</code> if so; <code>false</code> otherwise
0752             * @exception SQLException if a database access error occurs
0753             */
0754            boolean supportsCatalogsInIndexDefinitions() throws SQLException;
0755
0756            /**
0757             * Retrieves whether a catalog name can be used in a privilege definition statement.
0758             *
0759             * @return <code>true</code> if so; <code>false</code> otherwise
0760             * @exception SQLException if a database access error occurs
0761             */
0762            boolean supportsCatalogsInPrivilegeDefinitions()
0763                    throws SQLException;
0764
0765            /**
0766             * Retrieves whether this database supports positioned <code>DELETE</code>
0767             * statements.
0768             *
0769             * @return <code>true</code> if so; <code>false</code> otherwise
0770             * @exception SQLException if a database access error occurs
0771             */
0772            boolean supportsPositionedDelete() throws SQLException;
0773
0774            /**
0775             * Retrieves whether this database supports positioned <code>UPDATE</code>
0776             * statements.
0777             *
0778             * @return <code>true</code> if so; <code>false</code> otherwise
0779             * @exception SQLException if a database access error occurs
0780             */
0781            boolean supportsPositionedUpdate() throws SQLException;
0782
0783            /**
0784             * Retrieves whether this database supports <code>SELECT FOR UPDATE</code>
0785             * statements.
0786             *
0787             * @return <code>true</code> if so; <code>false</code> otherwise
0788             * @exception SQLException if a database access error occurs
0789             */
0790            boolean supportsSelectForUpdate() throws SQLException;
0791
0792            /**
0793             * Retrieves whether this database supports stored procedure calls 
0794             * that use the stored procedure escape syntax.
0795             *
0796             * @return <code>true</code> if so; <code>false</code> otherwise 
0797             * @exception SQLException if a database access error occurs
0798             */
0799            boolean supportsStoredProcedures() throws SQLException;
0800
0801            /**
0802             * Retrieves whether this database supports subqueries in comparison 
0803             * expressions.
0804             *
0805             * @return <code>true</code> if so; <code>false</code> otherwise
0806             * @exception SQLException if a database access error occurs
0807             */
0808            boolean supportsSubqueriesInComparisons() throws SQLException;
0809
0810            /**
0811             * Retrieves whether this database supports subqueries in 
0812             * <code>EXISTS</code> expressions.
0813             *
0814             * @return <code>true</code> if so; <code>false</code> otherwise
0815             * @exception SQLException if a database access error occurs
0816             */
0817            boolean supportsSubqueriesInExists() throws SQLException;
0818
0819            /**
0820             * Retrieves whether this database supports subqueries in 
0821             * <code>IN</code> expressions.
0822             *
0823             * @return <code>true</code> if so; <code>false</code> otherwise
0824             * @exception SQLException if a database access error occurs
0825             */
0826            boolean supportsSubqueriesInIns() throws SQLException;
0827
0828            /**
0829             * Retrieves whether this database supports subqueries in quantified 
0830             * expressions.
0831             *
0832             * @return <code>true</code> if so; <code>false</code> otherwise
0833             * @exception SQLException if a database access error occurs
0834             */
0835            boolean supportsSubqueriesInQuantifieds() throws SQLException;
0836
0837            /**
0838             * Retrieves whether this database supports correlated subqueries.
0839             *
0840             * @return <code>true</code> if so; <code>false</code> otherwise
0841             * @exception SQLException if a database access error occurs
0842             */
0843            boolean supportsCorrelatedSubqueries() throws SQLException;
0844
0845            /**
0846             * Retrieves whether this database supports SQL <code>UNION</code>.
0847             *
0848             * @return <code>true</code> if so; <code>false</code> otherwise
0849             * @exception SQLException if a database access error occurs
0850             */
0851            boolean supportsUnion() throws SQLException;
0852
0853            /**
0854             * Retrieves whether this database supports SQL <code>UNION ALL</code>.
0855             *
0856             * @return <code>true</code> if so; <code>false</code> otherwise
0857             * @exception SQLException if a database access error occurs
0858             */
0859            boolean supportsUnionAll() throws SQLException;
0860
0861            /**
0862             * Retrieves whether this database supports keeping cursors open 
0863             * across commits. 
0864             * 
0865             * @return <code>true</code> if cursors always remain open;
0866             *       <code>false</code> if they might not remain open
0867             * @exception SQLException if a database access error occurs
0868             */
0869            boolean supportsOpenCursorsAcrossCommit() throws SQLException;
0870
0871            /**
0872             * Retrieves whether this database supports keeping cursors open 
0873             * across rollbacks.
0874             * 
0875             * @return <code>true</code> if cursors always remain open;
0876             *       <code>false</code> if they might not remain open
0877             * @exception SQLException if a database access error occurs
0878             */
0879            boolean supportsOpenCursorsAcrossRollback() throws SQLException;
0880
0881            /**
0882             * Retrieves whether this database supports keeping statements open 
0883             * across commits.
0884             * 
0885             * @return <code>true</code> if statements always remain open;
0886             *       <code>false</code> if they might not remain open
0887             * @exception SQLException if a database access error occurs
0888             */
0889            boolean supportsOpenStatementsAcrossCommit() throws SQLException;
0890
0891            /**
0892             * Retrieves whether this database supports keeping statements open 
0893             * across rollbacks.
0894             * 
0895             * @return <code>true</code> if statements always remain open;
0896             *       <code>false</code> if they might not remain open
0897             * @exception SQLException if a database access error occurs
0898             */
0899            boolean supportsOpenStatementsAcrossRollback() throws SQLException;
0900
0901            //----------------------------------------------------------------------
0902            // The following group of methods exposes various limitations 
0903            // based on the target database with the current driver.
0904            // Unless otherwise specified, a result of zero means there is no
0905            // limit, or the limit is not known.
0906
0907            /**
0908             * Retrieves the maximum number of hex characters this database allows in an 
0909             * inline binary literal.
0910             *
0911             * @return max the maximum length (in hex characters) for a binary literal;
0912             *      a result of zero means that there is no limit or the limit 
0913             *      is not known
0914             * @exception SQLException if a database access error occurs
0915             */
0916            int getMaxBinaryLiteralLength() throws SQLException;
0917
0918            /**
0919             * Retrieves the maximum number of characters this database allows 
0920             * for a character literal.
0921             *
0922             * @return the maximum number of characters allowed for a character literal;
0923             *      a result of zero means that there is no limit or the limit is 
0924             *      not known
0925             * @exception SQLException if a database access error occurs
0926             */
0927            int getMaxCharLiteralLength() throws SQLException;
0928
0929            /**
0930             * Retrieves the maximum number of characters this database allows
0931             * for a column name.
0932             *
0933             * @return the maximum number of characters allowed for a column name;
0934             *      a result of zero means that there is no limit or the limit 
0935             *      is not known
0936             * @exception SQLException if a database access error occurs
0937             */
0938            int getMaxColumnNameLength() throws SQLException;
0939
0940            /**
0941             * Retrieves the maximum number of columns this database allows in a 
0942             * <code>GROUP BY</code> clause.
0943             *
0944             * @return the maximum number of columns allowed;
0945             *      a result of zero means that there is no limit or the limit 
0946             *      is not known
0947             * @exception SQLException if a database access error occurs
0948             */
0949            int getMaxColumnsInGroupBy() throws SQLException;
0950
0951            /**
0952             * Retrieves the maximum number of columns this database allows in an index.
0953             *
0954             * @return the maximum number of columns allowed;
0955             *      a result of zero means that there is no limit or the limit 
0956             *      is not known
0957             * @exception SQLException if a database access error occurs
0958             */
0959            int getMaxColumnsInIndex() throws SQLException;
0960
0961            /**
0962             * Retrieves the maximum number of columns this database allows in an 
0963             * <code>ORDER BY</code> clause.
0964             *
0965             * @return the maximum number of columns allowed;
0966             *      a result of zero means that there is no limit or the limit 
0967             *      is not known
0968             * @exception SQLException if a database access error occurs
0969             */
0970            int getMaxColumnsInOrderBy() throws SQLException;
0971
0972            /**
0973             * Retrieves the maximum number of columns this database allows in a 
0974             * <code>SELECT</code> list.
0975             *
0976             * @return the maximum number of columns allowed;
0977             *      a result of zero means that there is no limit or the limit 
0978             *      is not known
0979             * @exception SQLException if a database access error occurs
0980             */
0981            int getMaxColumnsInSelect() throws SQLException;
0982
0983            /**
0984             * Retrieves the maximum number of columns this database allows in a table.
0985             *
0986             * @return the maximum number of columns allowed;
0987             *      a result of zero means that there is no limit or the limit 
0988             *      is not known
0989             * @exception SQLException if a database access error occurs
0990             */
0991            int getMaxColumnsInTable() throws SQLException;
0992
0993            /**
0994             * Retrieves the maximum number of concurrent connections to this
0995             * database that are possible.
0996             *
0997             * @return the maximum number of active connections possible at one time;
0998             *      a result of zero means that there is no limit or the limit 
0999             *      is not known
1000             * @exception SQLException if a database access error occurs
1001             */
1002            int getMaxConnections() throws SQLException;
1003
1004            /**
1005             * Retrieves the maximum number of characters that this database allows in a
1006             * cursor name.
1007             *
1008             * @return the maximum number of characters allowed in a cursor name;
1009             *      a result of zero means that there is no limit or the limit 
1010             *      is not known
1011             * @exception SQLException if a database access error occurs
1012             */
1013            int getMaxCursorNameLength() throws SQLException;
1014
1015            /**
1016             * Retrieves the maximum number of bytes this database allows for an 
1017             * index, including all of the parts of the index.
1018             *
1019             * @return the maximum number of bytes allowed; this limit includes the 
1020             *      composite of all the constituent parts of the index;
1021             *      a result of zero means that there is no limit or the limit 
1022             *      is not known
1023             * @exception SQLException if a database access error occurs
1024             */
1025            int getMaxIndexLength() throws SQLException;
1026
1027            /**
1028             * Retrieves the maximum number of characters that this database allows in a
1029             * schema name.
1030             *
1031             * @return the maximum number of characters allowed in a schema name;
1032             *      a result of zero means that there is no limit or the limit 
1033             *      is not known
1034             * @exception SQLException if a database access error occurs
1035             */
1036            int getMaxSchemaNameLength() throws SQLException;
1037
1038            /**
1039             * Retrieves the maximum number of characters that this database allows in a
1040             * procedure name.
1041             *
1042             * @return the maximum number of characters allowed in a procedure name;
1043             *      a result of zero means that there is no limit or the limit 
1044             *      is not known
1045             * @exception SQLException if a database access error occurs
1046             */
1047            int getMaxProcedureNameLength() throws SQLException;
1048
1049            /**
1050             * Retrieves the maximum number of characters that this database allows in a
1051             * catalog name.
1052             *
1053             * @return the maximum number of characters allowed in a catalog name;
1054             *      a result of zero means that there is no limit or the limit 
1055             *      is not known
1056             * @exception SQLException if a database access error occurs
1057             */
1058            int getMaxCatalogNameLength() throws SQLException;
1059
1060            /**
1061             * Retrieves the maximum number of bytes this database allows in
1062             * a single row.
1063             *
1064             * @return the maximum number of bytes allowed for a row; a result of 
1065             *         zero means that there is no limit or the limit is not known
1066             * @exception SQLException if a database access error occurs
1067             */
1068            int getMaxRowSize() throws SQLException;
1069
1070            /**
1071             * Retrieves whether the return value for the method 
1072             * <code>getMaxRowSize</code> includes the SQL data types 
1073             * <code>LONGVARCHAR</code> and <code>LONGVARBINARY</code>.
1074             *
1075             * @return <code>true</code> if so; <code>false</code> otherwise 
1076             * @exception SQLException if a database access error occurs
1077             */
1078            boolean doesMaxRowSizeIncludeBlobs() throws SQLException;
1079
1080            /**
1081             * Retrieves the maximum number of characters this database allows in
1082             * an SQL statement.
1083             *
1084             * @return the maximum number of characters allowed for an SQL statement;
1085             *      a result of zero means that there is no limit or the limit 
1086             *      is not known
1087             * @exception SQLException if a database access error occurs
1088             */
1089            int getMaxStatementLength() throws SQLException;
1090
1091            /**
1092             * Retrieves the maximum number of active statements to this database
1093             * that can be open at the same time.
1094             *
1095             * @return the maximum number of statements that can be open at one time;
1096             *      a result of zero means that there is no limit or the limit 
1097             *      is not known
1098             * @exception SQLException if a database access error occurs
1099             */
1100            int getMaxStatements() throws SQLException;
1101
1102            /**
1103             * Retrieves the maximum number of characters this database allows in
1104             * a table name.
1105             *
1106             * @return the maximum number of characters allowed for a table name;
1107             *      a result of zero means that there is no limit or the limit 
1108             *      is not known
1109             * @exception SQLException if a database access error occurs
1110             */
1111            int getMaxTableNameLength() throws SQLException;
1112
1113            /**
1114             * Retrieves the maximum number of tables this database allows in a
1115             * <code>SELECT</code> statement.
1116             *
1117             * @return the maximum number of tables allowed in a <code>SELECT</code> 
1118             *         statement; a result of zero means that there is no limit or 
1119             *         the limit is not known
1120             * @exception SQLException if a database access error occurs
1121             */
1122            int getMaxTablesInSelect() throws SQLException;
1123
1124            /**
1125             * Retrieves the maximum number of characters this database allows in
1126             * a user name.
1127             *
1128             * @return the maximum number of characters allowed for a user name;
1129             *      a result of zero means that there is no limit or the limit 
1130             *      is not known
1131             * @exception SQLException if a database access error occurs
1132             */
1133            int getMaxUserNameLength() throws SQLException;
1134
1135            //----------------------------------------------------------------------
1136
1137            /**
1138             * Retrieves this database's default transaction isolation level.  The
1139             * possible values are defined in <code>java.sql.Connection</code>.
1140             *
1141             * @return the default isolation level 
1142             * @exception SQLException if a database access error occurs
1143             * @see Connection
1144             */
1145            int getDefaultTransactionIsolation() throws SQLException;
1146
1147            /**
1148             * Retrieves whether this database supports transactions. If not, invoking the
1149             * method <code>commit</code> is a noop, and the isolation level is 
1150             * <code>TRANSACTION_NONE</code>.
1151             *
1152             * @return <code>true</code> if transactions are supported; 
1153             *         <code>false</code> otherwise 
1154             * @exception SQLException if a database access error occurs
1155             */
1156            boolean supportsTransactions() throws SQLException;
1157
1158            /**
1159             * Retrieves whether this database supports the given transaction isolation level.
1160             *
1161             * @param level one of the transaction isolation levels defined in 
1162             *         <code>java.sql.Connection</code>
1163             * @return <code>true</code> if so; <code>false</code> otherwise 
1164             * @exception SQLException if a database access error occurs
1165             * @see Connection
1166             */
1167            boolean supportsTransactionIsolationLevel(int level)
1168                    throws SQLException;
1169
1170            /**
1171             * Retrieves whether this database supports both data definition and 
1172             * data manipulation statements within a transaction.
1173             *
1174             * @return <code>true</code> if so; <code>false</code> otherwise 
1175             * @exception SQLException if a database access error occurs
1176             */
1177            boolean supportsDataDefinitionAndDataManipulationTransactions()
1178                    throws SQLException;
1179
1180            /**
1181             * Retrieves whether this database supports only data manipulation 
1182             * statements within a transaction.
1183             *
1184             * @return <code>true</code> if so; <code>false</code> otherwise
1185             * @exception SQLException if a database access error occurs
1186             */
1187            boolean supportsDataManipulationTransactionsOnly()
1188                    throws SQLException;
1189
1190            /**
1191             * Retrieves whether a data definition statement within a transaction forces
1192             * the transaction to commit.
1193             *
1194             * @return <code>true</code> if so; <code>false</code> otherwise 
1195             * @exception SQLException if a database access error occurs
1196             */
1197            boolean dataDefinitionCausesTransactionCommit() throws SQLException;
1198
1199            /**
1200             * Retrieves whether this database ignores a data definition statement 
1201             * within a transaction.
1202             *
1203             * @return <code>true</code> if so; <code>false</code> otherwise 
1204             * @exception SQLException if a database access error occurs
1205             */
1206            boolean dataDefinitionIgnoredInTransactions() throws SQLException;
1207
1208            /**
1209             * Retrieves a description of the stored procedures available in the given
1210             * catalog.
1211             * <P>
1212             * Only procedure descriptions matching the schema and
1213             * procedure name criteria are returned.  They are ordered by
1214             * <code>PROCEDURE_CAT</code>, <code>PROCEDURE_SCHEM</code>,
1215             * <code>PROCEDURE_NAME</code> and <code>SPECIFIC_ NAME</code>.
1216             *
1217             * <P>Each procedure description has the the following columns:
1218             *  <OL>
1219             *	<LI><B>PROCEDURE_CAT</B> String => procedure catalog (may be <code>null</code>)
1220             *	<LI><B>PROCEDURE_SCHEM</B> String => procedure schema (may be <code>null</code>)
1221             *	<LI><B>PROCEDURE_NAME</B> String => procedure name
1222             *  <LI> reserved for future use
1223             *  <LI> reserved for future use
1224             *  <LI> reserved for future use
1225             *	<LI><B>REMARKS</B> String => explanatory comment on the procedure
1226             *	<LI><B>PROCEDURE_TYPE</B> short => kind of procedure:
1227             *      <UL>
1228             *      <LI> procedureResultUnknown - Cannot determine if  a return value
1229             *       will be returned
1230             *      <LI> procedureNoResult - Does not return a return value
1231             *      <LI> procedureReturnsResult - Returns a return value
1232             *      </UL>
1233             *	<LI><B>SPECIFIC_NAME</B> String  => The name which uniquely identifies this 
1234             * procedure within its schema. 
1235             *  </OL>
1236             * <p>
1237             * A user may not have permissions to execute any of the procedures that are
1238             * returned by <code>getProcedures</code>
1239             *
1240             * @param catalog a catalog name; must match the catalog name as it
1241             *        is stored in the database; "" retrieves those without a catalog;
1242             *        <code>null</code> means that the catalog name should not be used to narrow
1243             *        the search
1244             * @param schemaPattern a schema name pattern; must match the schema name
1245             *        as it is stored in the database; "" retrieves those without a schema;
1246             *        <code>null</code> means that the schema name should not be used to narrow
1247             *        the search
1248             * @param procedureNamePattern a procedure name pattern; must match the
1249             *        procedure name as it is stored in the database 
1250             * @return <code>ResultSet</code> - each row is a procedure description 
1251             * @exception SQLException if a database access error occurs
1252             * @see #getSearchStringEscape 
1253             */
1254            ResultSet getProcedures(String catalog, String schemaPattern,
1255                    String procedureNamePattern) throws SQLException;
1256
1257            /**
1258             * Indicates that it is not known whether the procedure returns
1259             * a result.
1260             * <P>
1261             * A possible value for column <code>PROCEDURE_TYPE</code> in the
1262             * <code>ResultSet</code> object returned by the method
1263             * <code>getProcedures</code>.
1264             */
1265            int procedureResultUnknown = 0;
1266
1267            /**
1268             * Indicates that the procedure does not return a result.
1269             * <P>
1270             * A possible value for column <code>PROCEDURE_TYPE</code> in the
1271             * <code>ResultSet</code> object returned by the method
1272             * <code>getProcedures</code>.
1273             */
1274            int procedureNoResult = 1;
1275
1276            /**
1277             * Indicates that the procedure returns a result.
1278             * <P>
1279             * A possible value for column <code>PROCEDURE_TYPE</code> in the
1280             * <code>ResultSet</code> object returned by the method
1281             * <code>getProcedures</code>.
1282             */
1283            int procedureReturnsResult = 2;
1284
1285            /**
1286             * Retrieves a description of the given catalog's stored procedure parameter
1287             * and result columns.
1288             *
1289             * <P>Only descriptions matching the schema, procedure and
1290             * parameter name criteria are returned.  They are ordered by
1291             * PROCEDURE_CAT, PROCEDURE_SCHEM, PROCEDURE_NAME and SPECIFIC_NAME. Within this, the return value,
1292             * if any, is first. Next are the parameter descriptions in call
1293             * order. The column descriptions follow in column number order.
1294             *
1295             * <P>Each row in the <code>ResultSet</code> is a parameter description or
1296             * column description with the following fields:
1297             *  <OL>
1298             *	<LI><B>PROCEDURE_CAT</B> String => procedure catalog (may be <code>null</code>)
1299             *	<LI><B>PROCEDURE_SCHEM</B> String => procedure schema (may be <code>null</code>)
1300             *	<LI><B>PROCEDURE_NAME</B> String => procedure name
1301             *	<LI><B>COLUMN_NAME</B> String => column/parameter name 
1302             *	<LI><B>COLUMN_TYPE</B> Short => kind of column/parameter:
1303             *      <UL>
1304             *      <LI> procedureColumnUnknown - nobody knows
1305             *      <LI> procedureColumnIn - IN parameter
1306             *      <LI> procedureColumnInOut - INOUT parameter
1307             *      <LI> procedureColumnOut - OUT parameter
1308             *      <LI> procedureColumnReturn - procedure return value
1309             *      <LI> procedureColumnResult - result column in <code>ResultSet</code>
1310             *      </UL>
1311             *  <LI><B>DATA_TYPE</B> int => SQL type from java.sql.Types
1312             *	<LI><B>TYPE_NAME</B> String => SQL type name, for a UDT type the
1313             *  type name is fully qualified
1314             *	<LI><B>PRECISION</B> int => precision
1315             *	<LI><B>LENGTH</B> int => length in bytes of data
1316             *	<LI><B>SCALE</B> short => scale -  null is returned for data types where  
1317             * SCALE is not applicable.
1318             *	<LI><B>RADIX</B> short => radix
1319             *	<LI><B>NULLABLE</B> short => can it contain NULL.
1320             *      <UL>
1321             *      <LI> procedureNoNulls - does not allow NULL values
1322             *      <LI> procedureNullable - allows NULL values
1323             *      <LI> procedureNullableUnknown - nullability unknown
1324             *      </UL>
1325             *	<LI><B>REMARKS</B> String => comment describing parameter/column
1326             * 	<LI><B>COLUMN_DEF</B> String => 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>)
1327             *      <UL>
1328             *      <LI> The string NULL (not enclosed in quotes) - if NULL was specified as the default value
1329             *      <LI> TRUNCATE (not enclosed in quotes)        - if the specified default value cannot be represented without truncation
1330             *      <LI> NULL                                     - if a default value was not specified
1331             *      </UL>
1332             *	<LI><B>SQL_DATA_TYPE</B> int  => reserved for future use
1333             *	<LI><B>SQL_DATETIME_SUB</B> int  => reserved for future use
1334             *	<LI><B>CHAR_OCTET_LENGTH</B> int  => the maximum length of binary and character based columns.  For any other datatype the returned value is a 
1335             * NULL
1336             *	<LI><B>ORDINAL_POSITION</B> int  => the ordinal position, starting from 1, for the input and output parameters for a procedure. A value of 0
1337             *is returned if this row describes the procedure's return value.  For result set columns, it is the
1338             *ordinal position of the column in the result set starting from 1.  If there are
1339             *multiple result sets, the column ordinal positions are implementation
1340             * defined.
1341             *	<LI><B>IS_NULLABLE</B> String  => ISO rules are used to determine the nullability for a column.
1342             *       <UL>
1343             *       <LI> YES           --- if the parameter can include NULLs
1344             *       <LI> NO            --- if the parameter cannot include NULLs
1345             *       <LI> empty string  --- if the nullability for the 
1346             * parameter is unknown
1347             *       </UL>
1348             *	<LI><B>SPECIFIC_NAME</B> String  => the name which uniquely identifies this procedure within its schema.
1349             *  </OL>
1350             *
1351             * <P><B>Note:</B> Some databases may not return the column
1352             * descriptions for a procedure. 
1353             * 
1354             * <p>The PRECISION column represents the specified column size for the given column. 
1355             * For numeric data, this is the maximum precision.  For character data, this is the length in characters. 
1356             * For datetime datatypes, this is the length in characters of the String representation (assuming the 
1357             * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype, 
1358             * this is the length in bytes. Null is returned for data types where the
1359             * column size is not applicable.
1360             * @param catalog a catalog name; must match the catalog name as it
1361             *        is stored in the database; "" retrieves those without a catalog;
1362             *        <code>null</code> means that the catalog name should not be used to narrow
1363             *        the search
1364             * @param schemaPattern a schema name pattern; must match the schema name
1365             *        as it is stored in the database; "" retrieves those without a schema;
1366             *        <code>null</code> means that the schema name should not be used to narrow
1367             *        the search
1368             * @param procedureNamePattern a procedure name pattern; must match the
1369             *        procedure name as it is stored in the database 
1370             * @param columnNamePattern a column name pattern; must match the column name
1371             *        as it is stored in the database 
1372             * @return <code>ResultSet</code> - each row describes a stored procedure parameter or 
1373             *      column
1374             * @exception SQLException if a database access error occurs
1375             * @see #getSearchStringEscape 
1376             */
1377            ResultSet getProcedureColumns(String catalog, String schemaPattern,
1378                    String procedureNamePattern, String columnNamePattern)
1379                    throws SQLException;
1380
1381            /**
1382             * Indicates that type of the column is unknown.
1383             * <P>
1384             * A possible value for the column
1385             * <code>COLUMN_TYPE</code>
1386             * in the <code>ResultSet</code> 
1387             * returned by the method <code>getProcedureColumns</code>.
1388             */
1389            int procedureColumnUnknown = 0;
1390
1391            /**
1392             * Indicates that the column stores IN parameters.
1393             * <P>
1394             * A possible value for the column
1395             * <code>COLUMN_TYPE</code>
1396             * in the <code>ResultSet</code> 
1397             * returned by the method <code>getProcedureColumns</code>.
1398             */
1399            int procedureColumnIn = 1;
1400
1401            /**
1402             * Indicates that the column stores INOUT parameters.
1403             * <P>
1404             * A possible value for the column
1405             * <code>COLUMN_TYPE</code>
1406             * in the <code>ResultSet</code> 
1407             * returned by the method <code>getProcedureColumns</code>.
1408             */
1409            int procedureColumnInOut = 2;
1410
1411            /**
1412             * Indicates that the column stores OUT parameters.
1413             * <P>
1414             * A possible value for the column
1415             * <code>COLUMN_TYPE</code>
1416             * in the <code>ResultSet</code> 
1417             * returned by the method <code>getProcedureColumns</code>.
1418             */
1419            int procedureColumnOut = 4;
1420            /**
1421             * Indicates that the column stores return values.
1422             * <P>
1423             * A possible value for the column
1424             * <code>COLUMN_TYPE</code>
1425             * in the <code>ResultSet</code> 
1426             * returned by the method <code>getProcedureColumns</code>.
1427             */
1428            int procedureColumnReturn = 5;
1429
1430            /**
1431             * Indicates that the column stores results.
1432             * <P>
1433             * A possible value for the column
1434             * <code>COLUMN_TYPE</code>
1435             * in the <code>ResultSet</code> 
1436             * returned by the method <code>getProcedureColumns</code>.
1437             */
1438            int procedureColumnResult = 3;
1439
1440            /**
1441             * Indicates that <code>NULL</code> values are not allowed.
1442             * <P>
1443             * A possible value for the column
1444             * <code>NULLABLE</code>
1445             * in the <code>ResultSet</code> object
1446             * returned by the method <code>getProcedureColumns</code>.
1447             */
1448            int procedureNoNulls = 0;
1449
1450            /**
1451             * Indicates that <code>NULL</code> values are allowed.
1452             * <P>
1453             * A possible value for the column
1454             * <code>NULLABLE</code>
1455             * in the <code>ResultSet</code> object
1456             * returned by the method <code>getProcedureColumns</code>.
1457             */
1458            int procedureNullable = 1;
1459
1460            /**
1461             * Indicates that whether <code>NULL</code> values are allowed
1462             * is unknown.
1463             * <P>
1464             * A possible value for the column
1465             * <code>NULLABLE</code>
1466             * in the <code>ResultSet</code> object
1467             * returned by the method <code>getProcedureColumns</code>.
1468             */
1469            int procedureNullableUnknown = 2;
1470
1471            /**
1472             * Retrieves a description of the tables available in the given catalog.
1473             * Only table descriptions matching the catalog, schema, table
1474             * name and type criteria are returned.  They are ordered by
1475             * <code>TABLE_TYPE</code>, <code>TABLE_CAT</code>, 
1476             * <code>TABLE_SCHEM</code> and <code>TABLE_NAME</code>.
1477             * <P>
1478             * Each table description has the following columns:
1479             *  <OL>
1480             *	<LI><B>TABLE_CAT</B> String => table catalog (may be <code>null</code>)
1481             *	<LI><B>TABLE_SCHEM</B> String => table schema (may be <code>null</code>)
1482             *	<LI><B>TABLE_NAME</B> String => table name
1483             *	<LI><B>TABLE_TYPE</B> String => table type.  Typical types are "TABLE",
1484             *			"VIEW",	"SYSTEM TABLE", "GLOBAL TEMPORARY", 
1485             *			"LOCAL TEMPORARY", "ALIAS", "SYNONYM".
1486             *	<LI><B>REMARKS</B> String => explanatory comment on the table
1487             *  <LI><B>TYPE_CAT</B> String => the types catalog (may be <code>null</code>)
1488             *  <LI><B>TYPE_SCHEM</B> String => the types schema (may be <code>null</code>)
1489             *  <LI><B>TYPE_NAME</B> String => type name (may be <code>null</code>)
1490             *  <LI><B>SELF_REFERENCING_COL_NAME</B> String => name of the designated 
1491             *                  "identifier" column of a typed table (may be <code>null</code>)
1492             *	<LI><B>REF_GENERATION</B> String => specifies how values in 
1493             *                  SELF_REFERENCING_COL_NAME are created. Values are
1494             *                  "SYSTEM", "USER", "DERIVED". (may be <code>null</code>)	
1495             *  </OL>
1496             *
1497             * <P><B>Note:</B> Some databases may not return information for
1498             * all tables.
1499             *
1500             * @param catalog a catalog name; must match the catalog name as it
1501             *        is stored in the database; "" retrieves those without a catalog;
1502             *        <code>null</code> means that the catalog name should not be used to narrow
1503             *        the search
1504             * @param schemaPattern a schema name pattern; must match the schema name
1505             *        as it is stored in the database; "" retrieves those without a schema;
1506             *        <code>null</code> means that the schema name should not be used to narrow
1507             *        the search
1508             * @param tableNamePattern a table name pattern; must match the
1509             *        table name as it is stored in the database 
1510             * @param types a list of table types, which must be from the list of table types 
1511             *         returned from {@link #getTableTypes},to include; <code>null</code> returns
1512             * all types
1513             * @return <code>ResultSet</code> - each row is a table description
1514             * @exception SQLException if a database access error occurs
1515             * @see #getSearchStringEscape 
1516             */
1517            ResultSet getTables(String catalog, String schemaPattern,
1518                    String tableNamePattern, String types[])
1519                    throws SQLException;
1520
1521            /**
1522             * Retrieves the schema names available in this database.  The results
1523             * are ordered by <code>TABLE_CATALOG</code> and 
1524             * <code>TABLE_SCHEM</code>.
1525             *
1526             * <P>The schema columns are:
1527             *  <OL>
1528             *	<LI><B>TABLE_SCHEM</B> String => schema name
1529             *  <LI><B>TABLE_CATALOG</B> String => catalog name (may be <code>null</code>)
1530             *  </OL>
1531             *
1532             * @return a <code>ResultSet</code> object in which each row is a 
1533             *         schema description 
1534             * @exception SQLException if a database access error occurs
1535             *
1536             */
1537            ResultSet getSchemas() throws SQLException;
1538
1539            /**
1540             * Retrieves the catalog names available in this database.  The results
1541             * are ordered by catalog name.
1542             *
1543             * <P>The catalog column is:
1544             *  <OL>
1545             *	<LI><B>TABLE_CAT</B> String => catalog name
1546             *  </OL>
1547             *
1548             * @return a <code>ResultSet</code> object in which each row has a 
1549             *         single <code>String</code> column that is a catalog name 
1550             * @exception SQLException if a database access error occurs
1551             */
1552            ResultSet getCatalogs() throws SQLException;
1553
1554            /**
1555             * Retrieves the table types available in this database.  The results
1556             * are ordered by table type.
1557             *
1558             * <P>The table type is:
1559             *  <OL>
1560             *	<LI><B>TABLE_TYPE</B> String => table type.  Typical types are "TABLE",
1561             *			"VIEW",	"SYSTEM TABLE", "GLOBAL TEMPORARY", 
1562             *			"LOCAL TEMPORARY", "ALIAS", "SYNONYM".
1563             *  </OL>
1564             *
1565             * @return a <code>ResultSet</code> object in which each row has a 
1566             *         single <code>String</code> column that is a table type 
1567             * @exception SQLException if a database access error occurs
1568             */
1569            ResultSet getTableTypes() throws SQLException;
1570
1571            /**
1572             * Retrieves a description of table columns available in 
1573             * the specified catalog.
1574             *
1575             * <P>Only column descriptions matching the catalog, schema, table
1576             * and column name criteria are returned.  They are ordered by
1577             * <code>TABLE_CAT</code>,<code>TABLE_SCHEM</code>, 
1578             * <code>TABLE_NAME</code>, and <code>ORDINAL_POSITION</code>.
1579             *
1580             * <P>Each column description has the following columns:
1581             *  <OL>
1582             *	<LI><B>TABLE_CAT</B> String => table catalog (may be <code>null</code>)
1583             *	<LI><B>TABLE_SCHEM</B> String => table schema (may be <code>null</code>)
1584             *	<LI><B>TABLE_NAME</B> String => table name
1585             *	<LI><B>COLUMN_NAME</B> String => column name
1586             *	<LI><B>DATA_TYPE</B> int => SQL type from java.sql.Types
1587             *	<LI><B>TYPE_NAME</B> String => Data source dependent type name,
1588             *  for a UDT the type name is fully qualified
1589             *	<LI><B>COLUMN_SIZE</B> int => column size.  
1590             *	<LI><B>BUFFER_LENGTH</B> is not used.
1591             *	<LI><B>DECIMAL_DIGITS</B> int => the number of fractional digits. Null is returned for data types where  
1592             * DECIMAL_DIGITS is not applicable.
1593             *	<LI><B>NUM_PREC_RADIX</B> int => Radix (typically either 10 or 2)
1594             *	<LI><B>NULLABLE</B> int => is NULL allowed.
1595             *      <UL>
1596             *      <LI> columnNoNulls - might not allow <code>NULL</code> values
1597             *      <LI> columnNullable - definitely allows <code>NULL</code> values
1598             *      <LI> columnNullableUnknown - nullability unknown
1599             *      </UL>
1600             *	<LI><B>REMARKS</B> String => comment describing column (may be <code>null</code>)
1601             * 	<LI><B>COLUMN_DEF</B> String => 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>)
1602             *	<LI><B>SQL_DATA_TYPE</B> int => unused
1603             *	<LI><B>SQL_DATETIME_SUB</B> int => unused
1604             *	<LI><B>CHAR_OCTET_LENGTH</B> int => for char types the 
1605             *       maximum number of bytes in the column
1606             *	<LI><B>ORDINAL_POSITION</B> int	=> index of column in table 
1607             *      (starting at 1)
1608             *	<LI><B>IS_NULLABLE</B> String  => ISO rules are used to determine the nullability for a column.
1609             *       <UL>
1610             *       <LI> YES           --- if the parameter can include NULLs
1611             *       <LI> NO            --- if the parameter cannot include NULLs
1612             *       <LI> empty string  --- if the nullability for the 
1613             * parameter is unknown
1614             *       </UL>
1615             *  <LI><B>SCOPE_CATLOG</B> String => catalog of table that is the scope
1616             *      of a reference attribute (<code>null</code> if DATA_TYPE isn't REF)
1617             *  <LI><B>SCOPE_SCHEMA</B> String => schema of table that is the scope
1618             *      of a reference attribute (<code>null</code> if the DATA_TYPE isn't REF)
1619             *  <LI><B>SCOPE_TABLE</B> String => table name that this the scope
1620             *      of a reference attribure (<code>null</code> if the DATA_TYPE isn't REF)
1621             *  <LI><B>SOURCE_DATA_TYPE</B> short => source type of a distinct type or user-generated
1622             *      Ref type, SQL type from java.sql.Types (<code>null</code> if DATA_TYPE 
1623             *      isn't DISTINCT or user-generated REF)
1624             *   <LI><B>IS_AUTOINCREMENT</B> String  => Indicates whether this column is auto incremented
1625             *       <UL>
1626             *       <LI> YES           --- if the column is auto incremented
1627             *       <LI> NO            --- if the column is not auto incremented
1628             *       <LI> empty string  --- if it cannot be determined whether the column is auto incremented
1629             * parameter is unknown
1630             *       </UL>
1631             *  </OL>
1632             *    
1633             * <p>The COLUMN_SIZE column the specified column size for the given column. 
1634             * For numeric data, this is the maximum precision.  For character data, this is the length in characters. 
1635             * For datetime datatypes, this is the length in characters of the String representation (assuming the 
1636             * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype, 
1637             * this is the length in bytes. Null is returned for data types where the
1638             * column size is not applicable.
1639             *
1640             * @param catalog a catalog name; must match the catalog name as it
1641             *        is stored in the database; "" retrieves those without a catalog;
1642             *        <code>null</code> means that the catalog name should not be used to narrow
1643             *        the search
1644             * @param schemaPattern a schema name pattern; must match the schema name
1645             *        as it is stored in the database; "" retrieves those without a schema;
1646             *        <code>null</code> means that the schema name should not be used to narrow
1647             *        the search
1648             * @param tableNamePattern a table name pattern; must match the
1649             *        table name as it is stored in the database 
1650             * @param columnNamePattern a column name pattern; must match the column
1651             *        name as it is stored in the database
1652             * @return <code>ResultSet</code> - each row is a column description
1653             * @exception SQLException if a database access error occurs
1654             * @see #getSearchStringEscape 
1655             */
1656            ResultSet getColumns(String catalog, String schemaPattern,
1657                    String tableNamePattern, String columnNamePattern)
1658                    throws SQLException;
1659
1660            /**
1661             * Indicates that the column might not allow <code>NULL</code> values.
1662             * <P>
1663             * A possible value for the column
1664             * <code>NULLABLE</code>
1665             * in the <code>ResultSet</code> returned by the method
1666             * <code>getColumns</code>.
1667             */
1668            int columnNoNulls = 0;
1669
1670            /**
1671             * Indicates that the column definitely allows <code>NULL</code> values.
1672             * <P>
1673             * A possible value for the column
1674             * <code>NULLABLE</code>
1675             * in the <code>ResultSet</code> returned by the method
1676             * <code>getColumns</code>.
1677             */
1678            int columnNullable = 1;
1679
1680            /**
1681             * Indicates that the nullability of columns is unknown.
1682             * <P>
1683             * A possible value for the column
1684             * <code>NULLABLE</code>
1685             * in the <code>ResultSet</code> returned by the method
1686             * <code>getColumns</code>.
1687             */
1688            int columnNullableUnknown = 2;
1689
1690            /**
1691             * Retrieves a description of the access rights for a table's columns.
1692             *
1693             * <P>Only privileges matching the column name criteria are
1694             * returned.  They are ordered by COLUMN_NAME and PRIVILEGE.
1695             *
1696             * <P>Each privilige description has the following columns:
1697             *  <OL>
1698             *	<LI><B>TABLE_CAT</B> String => table catalog (may be <code>null</code>)
1699             *	<LI><B>TABLE_SCHEM</B> String => table schema (may be <code>null</code>)
1700             *	<LI><B>TABLE_NAME</B> String => table name
1701             *	<LI><B>COLUMN_NAME</B> String => column name
1702             *	<LI><B>GRANTOR</B> String => grantor of access (may be <code>null</code>)
1703             *	<LI><B>GRANTEE</B> String => grantee of access
1704             *	<LI><B>PRIVILEGE</B> String => name of access (SELECT, 
1705             *      INSERT, UPDATE, REFRENCES, ...)
1706             *	<LI><B>IS_GRANTABLE</B> String => "YES" if grantee is permitted 
1707             *      to grant to others; "NO" if not; <code>null</code> if unknown 
1708             *  </OL>
1709             *
1710             * @param catalog a catalog name; must match the catalog name as it
1711             *        is stored in the database; "" retrieves those without a catalog;
1712             *        <code>null</code> means that the catalog name should not be used to narrow
1713             *        the search
1714             * @param schema a schema name; must match the schema name as it is
1715             *        stored in the database; "" retrieves those without a schema;
1716             *        <code>null</code> means that the schema name should not be used to narrow
1717             *        the search
1718             * @param table a table name; must match the table name as it is
1719             *        stored in the database 
1720             * @param columnNamePattern a column name pattern; must match the column
1721             *        name as it is stored in the database
1722             * @return <code>ResultSet</code> - each row is a column privilege description
1723             * @exception SQLException if a database access error occurs
1724             * @see #getSearchStringEscape 
1725             */
1726            ResultSet getColumnPrivileges(String catalog, String schema,
1727                    String table, String columnNamePattern) throws SQLException;
1728
1729            /**
1730             * Retrieves a description of the access rights for each table available
1731             * in a catalog. Note that a table privilege applies to one or
1732             * more columns in the table. It would be wrong to assume that
1733             * this privilege applies to all columns (this may be true for
1734             * some systems but is not true for all.)
1735             *
1736             * <P>Only privileges matching the schema and table name
1737             * criteria are returned.  They are ordered by 
1738             * <code>TABLE_CAT</code>, 
1739             * <code>TABLE_SCHEM</code>, <code>TABLE_NAME</code>,
1740             * and <code>PRIVILEGE</code>.
1741             *
1742             * <P>Each privilige description has the following columns:
1743             *  <OL>
1744             *	<LI><B>TABLE_CAT</B> String => table catalog (may be <code>null</code>)
1745             *	<LI><B>TABLE_SCHEM</B> String => table schema (may be <code>null</code>)
1746             *	<LI><B>TABLE_NAME</B> String => table name
1747             *	<LI><B>GRANTOR</B> String => grantor of access (may be <code>null</code>)
1748             *	<LI><B>GRANTEE</B> String => grantee of access
1749             *	<LI><B>PRIVILEGE</B> String => name of access (SELECT, 
1750             *      INSERT, UPDATE, REFRENCES, ...)
1751             *	<LI><B>IS_GRANTABLE</B> String => "YES" if grantee is permitted 
1752             *      to grant to others; "NO" if not; <code>null</code> if unknown 
1753             *  </OL>
1754             *
1755             * @param catalog a catalog name; must match the catalog name as it
1756             *        is stored in the database; "" retrieves those without a catalog;
1757             *        <code>null</code> means that the catalog name should not be used to narrow
1758             *        the search
1759             * @param schemaPattern a schema name pattern; must match the schema name
1760             *        as it is stored in the database; "" retrieves those without a schema;
1761             *        <code>null</code> means that the schema name should not be used to narrow
1762             *        the search
1763             * @param tableNamePattern a table name pattern; must match the
1764             *        table name as it is stored in the database 
1765             * @return <code>ResultSet</code> - each row is a table privilege description
1766             * @exception SQLException if a database access error occurs
1767             * @see #getSearchStringEscape 
1768             */
1769            ResultSet getTablePrivileges(String catalog, String schemaPattern,
1770                    String tableNamePattern) throws SQLException;
1771
1772            /**
1773             * Retrieves a description of a table's optimal set of columns that
1774             * uniquely identifies a row. They are ordered by SCOPE.
1775             *
1776             * <P>Each column description has the following columns:
1777             *  <OL>
1778             *	<LI><B>SCOPE</B> short => actual scope of result
1779             *      <UL>
1780             *      <LI> bestRowTemporary - very temporary, while using row
1781             *      <LI> bestRowTransaction - valid for remainder of current transaction
1782             *      <LI> bestRowSession - valid for remainder of current session
1783             *      </UL>
1784             *	<LI><B>COLUMN_NAME</B> String => column name
1785             *	<LI><B>DATA_TYPE</B> int => SQL data type from java.sql.Types
1786             *	<LI><B>TYPE_NAME</B> String => Data source dependent type name,
1787             *  for a UDT the type name is fully qualified
1788             *	<LI><B>COLUMN_SIZE</B> int => precision
1789             *	<LI><B>BUFFER_LENGTH</B> int => not used
1790             *	<LI><B>DECIMAL_DIGITS</B> short	 => scale - Null is returned for data types where  
1791             * DECIMAL_DIGITS is not applicable.
1792             *	<LI><B>PSEUDO_COLUMN</B> short => is this a pseudo column 
1793             *      like an Oracle ROWID
1794             *      <UL>
1795             *      <LI> bestRowUnknown - may or may not be pseudo column
1796             *      <LI> bestRowNotPseudo - is NOT a pseudo column
1797             *      <LI> bestRowPseudo - is a pseudo column
1798             *      </UL>
1799             *  </OL>
1800             *
1801             * <p>The COLUMN_SIZE column represents the specified column size for the given column. 
1802             * For numeric data, this is the maximum precision.  For character data, this is the length in characters. 
1803             * For datetime datatypes, this is the length in characters of the String representation (assuming the 
1804             * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype, 
1805             * this is the length in bytes. Null is returned for data types where the
1806             * column size is not applicable.
1807             *
1808             * @param catalog a catalog name; must match the catalog name as it
1809             *        is stored in the database; "" retrieves those without a catalog;
1810             *        <code>null</code> means that the catalog name should not be used to narrow
1811             *        the search
1812             * @param schema a schema name; must match the schema name
1813             *        as it is stored in the database; "" retrieves those without a schema;
1814             *        <code>null</code> means that the schema name should not be used to narrow
1815             *        the search
1816             * @param table a table name; must match the table name as it is stored 
1817             *        in the database 
1818             * @param scope the scope of interest; use same values as SCOPE
1819             * @param nullable include columns that are nullable.
1820             * @return <code>ResultSet</code> - each row is a column description 
1821             * @exception SQLException if a database access error occurs
1822             */
1823            ResultSet getBestRowIdentifier(String catalog, String schema,
1824                    String table, int scope, boolean nullable)
1825                    throws SQLException;
1826
1827            /**
1828             * Indicates that the scope of the best row identifier is
1829             * very temporary, lasting only while the
1830             * row is being used.
1831             * <P>
1832             * A possible value for the column
1833             * <code>SCOPE</code>
1834             * in the <code>ResultSet</code> object
1835             * returned by the method <code>getBestRowIdentifier</code>.
1836             */
1837            int bestRowTemporary = 0;
1838
1839            /**
1840             * Indicates that the scope of the best row identifier is
1841             * the remainder of the current transaction.
1842             * <P>
1843             * A possible value for the column
1844             * <code>SCOPE</code>
1845             * in the <code>ResultSet</code> object
1846             * returned by the method <code>getBestRowIdentifier</code>.
1847             */
1848            int bestRowTransaction = 1;
1849
1850            /**
1851             * Indicates that the scope of the best row identifier is
1852             * the remainder of the current session.
1853             * <P>
1854             * A possible value for the column
1855             * <code>SCOPE</code>
1856             * in the <code>ResultSet</code> object
1857             * returned by the method <code>getBestRowIdentifier</code>.
1858             */
1859            int bestRowSession = 2;
1860
1861            /**
1862             * Indicates that the best row identifier may or may not be a pseudo column.
1863             * <P>
1864             * A possible value for the column
1865             * <code>PSEUDO_COLUMN</code>
1866             * in the <code>ResultSet</code> object
1867             * returned by the method <code>getBestRowIdentifier</code>.
1868             */
1869            int bestRowUnknown = 0;
1870
1871            /**
1872             * Indicates that the best row identifier is NOT a pseudo column.
1873             * <P>
1874             * A possible value for the column
1875             * <code>PSEUDO_COLUMN</code>
1876             * in the <code>ResultSet</code> object
1877             * returned by the method <code>getBestRowIdentifier</code>.
1878             */
1879            int bestRowNotPseudo = 1;
1880
1881            /**
1882             * Indicates that the best row identifier is a pseudo column.
1883             * <P>
1884             * A possible value for the column
1885             * <code>PSEUDO_COLUMN</code>
1886             * in the <code>ResultSet</code> object
1887             * returned by the method <code>getBestRowIdentifier</code>.
1888             */
1889            int bestRowPseudo = 2;
1890
1891            /**
1892             * Retrieves a description of a table's columns that are automatically
1893             * updated when any value in a row is updated.  They are
1894             * unordered.
1895             *
1896             * <P>Each column description has the following columns:
1897             *  <OL>
1898             *	<LI><B>SCOPE</B> short => is not used
1899             *	<LI><B>COLUMN_NAME</B> String => column name
1900             *	<LI><B>DATA_TYPE</B> int => SQL data type from <code>java.sql.Types</code>
1901             *	<LI><B>TYPE_NAME</B> String => Data source-dependent type name
1902             *	<LI><B>COLUMN_SIZE</B> int => precision
1903             *	<LI><B>BUFFER_LENGTH</B> int => length of column value in bytes
1904             *	<LI><B>DECIMAL_DIGITS</B> short	 => scale - Null is returned for data types where  
1905             * DECIMAL_DIGITS is not applicable.
1906             *	<LI><B>PSEUDO_COLUMN</B> short => whether this is pseudo column 
1907             *      like an Oracle ROWID
1908             *      <UL>
1909             *      <LI> versionColumnUnknown - may or may not be pseudo column
1910             *      <LI> versionColumnNotPseudo - is NOT a pseudo column
1911             *      <LI> versionColumnPseudo - is a pseudo column
1912             *      </UL>
1913             *  </OL>
1914             *    
1915             * <p>The COLUMN_SIZE column represents the specified column size for the given column. 
1916             * For numeric data, this is the maximum precision.  For character data, this is the length in characters. 
1917             * For datetime datatypes, this is the length in characters of the String representation (assuming the 
1918             * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype, 
1919             * this is the length in bytes. Null is returned for data types where the
1920             * column size is not applicable.
1921             * @param catalog a catalog name; must match the catalog name as it
1922             *        is stored in the database; "" retrieves those without a catalog;
1923             *        <code>null</code> means that the catalog name should not be used to narrow
1924             *        the search
1925             * @param schema a schema name; must match the schema name
1926             *        as it is stored in the database; "" retrieves those without a schema;
1927             *        <code>null</code> means that the schema name should not be used to narrow
1928             *        the search
1929             * @param table a table name; must match the table name as it is stored 
1930             *        in the database 
1931             * @return a <code>ResultSet</code> object in which each row is a 
1932             *         column description 
1933             * @exception SQLException if a database access error occurs
1934             */
1935            ResultSet getVersionColumns(String catalog, String schema,
1936                    String table) throws SQLException;
1937
1938            /**
1939             * Indicates that this version column may or may not be a pseudo column.
1940             * <P>
1941             * A possible value for the column
1942             * <code>PSEUDO_COLUMN</code>
1943             * in the <code>ResultSet</code> object
1944             * returned by the method <code>getVersionColumns</code>.
1945             */
1946            int versionColumnUnknown = 0;
1947
1948            /**
1949             * Indicates that this version column is NOT a pseudo column.
1950             * <P>
1951             * A possible value for the column
1952             * <code>PSEUDO_COLUMN</code>
1953             * in the <code>ResultSet</code> object
1954             * returned by the method <code>getVersionColumns</code>.
1955             */
1956            int versionColumnNotPseudo = 1;
1957
1958            /**
1959             * Indicates that this version column is a pseudo column.
1960             * <P>
1961             * A possible value for the column
1962             * <code>PSEUDO_COLUMN</code>
1963             * in the <code>ResultSet</code> object
1964             * returned by the method <code>getVersionColumns</code>.
1965             */
1966            int versionColumnPseudo = 2;
1967
1968            /**
1969             * Retrieves a description of the given table's primary key columns.  They
1970             * are ordered by COLUMN_NAME.
1971             *
1972             * <P>Each primary key column description has the following columns:
1973             *  <OL>
1974             *	<LI><B>TABLE_CAT</B> String => table catalog (may be <code>null</code>)
1975             *	<LI><B>TABLE_SCHEM</B> String => table schema (may be <code>null</code>)
1976             *	<LI><B>TABLE_NAME</B> String => table name
1977             *	<LI><B>COLUMN_NAME</B> String => column name
1978             *	<LI><B>KEY_SEQ</B> short => sequence number within primary key( a value
1979             *  of 1 represents the first column of the primary key, a value of 2 would
1980             *  represent the second column within the primary key).
1981             *	<LI><B>PK_NAME</B> String => primary key name (may be <code>null</code>)
1982             *  </OL>
1983             *
1984             * @param catalog a catalog name; must match the catalog name as it
1985             *        is stored in the database; "" retrieves those without a catalog;
1986             *        <code>null</code> means that the catalog name should not be used to narrow
1987             *        the search
1988             * @param schema a schema name; must match the schema name
1989             *        as it is stored in the database; "" retrieves those without a schema;
1990             *        <code>null</code> means that the schema name should not be used to narrow
1991             *        the search
1992             * @param table a table name; must match the table name as it is stored 
1993             *        in the database 
1994             * @return <code>ResultSet</code> - each row is a primary key column description 
1995             * @exception SQLException if a database access error occurs
1996             */
1997            ResultSet getPrimaryKeys(String catalog, String schema, String table)
1998                    throws SQLException;
1999
2000            /**
2001             * Retrieves a description of the primary key columns that are
2002             * referenced by the given table's foreign key columns (the primary keys
2003             * imported by a table).  They are ordered by PKTABLE_CAT,
2004             * PKTABLE_SCHEM, PKTABLE_NAME, and KEY_SEQ.
2005             *
2006             * <P>Each primary key column description has the following columns:
2007             *  <OL>
2008             *	<LI><B>PKTABLE_CAT</B> String => primary key table catalog 
2009             *      being imported (may be <code>null</code>)
2010             *	<LI><B>PKTABLE_SCHEM</B> String => primary key table schema
2011             *      being imported (may be <code>null</code>)
2012             *	<LI><B>PKTABLE_NAME</B> String => primary key table name
2013             *      being imported
2014             *	<LI><B>PKCOLUMN_NAME</B> String => primary key column name
2015             *      being imported
2016             *	<LI><B>FKTABLE_CAT</B> String => foreign key table catalog (may be <code>null</code>)
2017             *	<LI><B>FKTABLE_SCHEM</B> String => foreign key table schema (may be <code>null</code>)
2018             *	<LI><B>FKTABLE_NAME</B> String => foreign key table name
2019             *	<LI><B>FKCOLUMN_NAME</B> String => foreign key column name
2020             *	<LI><B>KEY_SEQ</B> short => sequence number within a foreign key( a value
2021             *  of 1 represents the first column of the foreign key, a value of 2 would
2022             *  represent the second column within the foreign key).
2023             *	<LI><B>UPDATE_RULE</B> short => What happens to a
2024             *       foreign key when the primary key is updated:
2025             *      <UL>
2026             *      <LI> importedNoAction - do not allow update of primary 
2027             *               key if it has been imported
2028             *      <LI> importedKeyCascade - change imported key to agree 
2029             *               with primary key update
2030             *      <LI> importedKeySetNull - change imported key to <code>NULL</code>
2031             *               if its primary key has been updated
2032             *      <LI> importedKeySetDefault - change imported key to default values 
2033             *               if its primary key has been updated
2034             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2035             *                                 (for ODBC 2.x compatibility)
2036             *      </UL>
2037             *	<LI><B>DELETE_RULE</B> short => What happens to 
2038             *      the foreign key when primary is deleted.
2039             *      <UL>
2040             *      <LI> importedKeyNoAction - do not allow delete of primary 
2041             *               key if it has been imported
2042             *      <LI> importedKeyCascade - delete rows that import a deleted key
2043             *      <LI> importedKeySetNull - change imported key to NULL if 
2044             *               its primary key has been deleted
2045             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2046             *                                 (for ODBC 2.x compatibility)
2047             *      <LI> importedKeySetDefault - change imported key to default if 
2048             *               its primary key has been deleted
2049             *      </UL>
2050             *	<LI><B>FK_NAME</B> String => foreign key name (may be <code>null</code>)
2051             *	<LI><B>PK_NAME</B> String => primary key name (may be <code>null</code>)
2052             *	<LI><B>DEFERRABILITY</B> short => can the evaluation of foreign key 
2053             *      constraints be deferred until commit
2054             *      <UL>
2055             *      <LI> importedKeyInitiallyDeferred - see SQL92 for definition
2056             *      <LI> importedKeyInitiallyImmediate - see SQL92 for definition 
2057             *      <LI> importedKeyNotDeferrable - see SQL92 for definition 
2058             *      </UL>
2059             *  </OL>
2060             *
2061             * @param catalog a catalog name; must match the catalog name as it
2062             *        is stored in the database; "" retrieves those without a catalog;
2063             *        <code>null</code> means that the catalog name should not be used to narrow
2064             *        the search
2065             * @param schema a schema name; must match the schema name
2066             *        as it is stored in the database; "" retrieves those without a schema;
2067             *        <code>null</code> means that the schema name should not be used to narrow
2068             *        the search
2069             * @param table a table name; must match the table name as it is stored 
2070             *        in the database 
2071             * @return <code>ResultSet</code> - each row is a primary key column description 
2072             * @exception SQLException if a database access error occurs
2073             * @see #getExportedKeys 
2074             */
2075            ResultSet getImportedKeys(String catalog, String schema,
2076                    String table) throws SQLException;
2077
2078            /**
2079             * For the column <code>UPDATE_RULE</code>,
2080             * indicates that
2081             * when the primary key is updated, the foreign key (imported key)
2082             * is changed to agree with it.
2083             * For the column <code>DELETE_RULE</code>,
2084             * it indicates that
2085             * when the primary key is deleted, rows that imported that key
2086             * are deleted.
2087             * <P>
2088             * A possible value for the columns <code>UPDATE_RULE</code>
2089             * and <code>DELETE_RULE</code> in the
2090             * <code>ResultSet</code> objects returned by the methods
2091             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2092             * and <code>getCrossReference</code>.
2093             */
2094            int importedKeyCascade = 0;
2095
2096            /**
2097             * For the column <code>UPDATE_RULE</code>, indicates that
2098             * a primary key may not be updated if it has been imported by
2099             * another table as a foreign key.
2100             * For the column <code>DELETE_RULE</code>, indicates that
2101             * a primary key may not be deleted if it has been imported by
2102             * another table as a foreign key.
2103             * <P>
2104             * A possible value for the columns <code>UPDATE_RULE</code>
2105             * and <code>DELETE_RULE</code> in the
2106             * <code>ResultSet</code> objects returned by the methods
2107             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2108             * and <code>getCrossReference</code>.
2109             */
2110            int importedKeyRestrict = 1;
2111
2112            /**
2113             * For the columns <code>UPDATE_RULE</code>
2114             * and <code>DELETE_RULE</code>, indicates that
2115             * when the primary key is updated or deleted, the foreign key (imported key)
2116             * is changed to <code>NULL</code>.
2117             * <P>
2118             * A possible value for the columns <code>UPDATE_RULE</code>
2119             * and <code>DELETE_RULE</code> in the
2120             * <code>ResultSet</code> objects returned by the methods
2121             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2122             * and <code>getCrossReference</code>.
2123             */
2124            int importedKeySetNull = 2;
2125
2126            /**
2127             * For the columns <code>UPDATE_RULE</code>
2128             * and <code>DELETE_RULE</code>, indicates that
2129             * if the primary key has been imported, it cannot be updated or deleted.
2130             * <P>
2131             * A possible value for the columns <code>UPDATE_RULE</code>
2132             * and <code>DELETE_RULE</code> in the
2133             * <code>ResultSet</code> objects returned by the methods
2134             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2135             * and <code>getCrossReference</code>.
2136             */
2137            int importedKeyNoAction = 3;
2138
2139            /**
2140             * For the columns <code>UPDATE_RULE</code>
2141             * and <code>DELETE_RULE</code>, indicates that
2142             * if the primary key is updated or deleted, the foreign key (imported key)
2143             * is set to the default value.
2144             * <P>
2145             * A possible value for the columns <code>UPDATE_RULE</code>
2146             * and <code>DELETE_RULE</code> in the
2147             * <code>ResultSet</code> objects returned by the methods
2148             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2149             * and <code>getCrossReference</code>.
2150             */
2151            int importedKeySetDefault = 4;
2152
2153            /**
2154             * Indicates deferrability.  See SQL-92 for a definition.
2155             * <P>
2156             * A possible value for the column <code>DEFERRABILITY</code>
2157             * in the <code>ResultSet</code> objects returned by the methods
2158             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2159             * and <code>getCrossReference</code>.
2160             */
2161            int importedKeyInitiallyDeferred = 5;
2162
2163            /**
2164             * Indicates deferrability.  See SQL-92 for a definition.
2165             * <P>
2166             * A possible value for the column <code>DEFERRABILITY</code>
2167             * in the <code>ResultSet</code> objects returned by the methods
2168             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2169             * and <code>getCrossReference</code>.
2170             */
2171            int importedKeyInitiallyImmediate = 6;
2172
2173            /**
2174             * Indicates deferrability.  See SQL-92 for a definition.
2175             * <P>
2176             * A possible value for the column <code>DEFERRABILITY</code>
2177             * in the <code>ResultSet</code> objects returned by the methods
2178             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2179             * and <code>getCrossReference</code>.
2180             */
2181            int importedKeyNotDeferrable = 7;
2182
2183            /**
2184             * Retrieves a description of the foreign key columns that reference the
2185             * given table's primary key columns (the foreign keys exported by a
2186             * table).  They are ordered by FKTABLE_CAT, FKTABLE_SCHEM,
2187             * FKTABLE_NAME, and KEY_SEQ.
2188             *
2189             * <P>Each foreign key column description has the following columns:
2190             *  <OL>
2191             *	<LI><B>PKTABLE_CAT</B> String => primary key table catalog (may be <code>null</code>)
2192             *	<LI><B>PKTABLE_SCHEM</B> String => primary key table schema (may be <code>null</code>)
2193             *	<LI><B>PKTABLE_NAME</B> String => primary key table name
2194             *	<LI><B>PKCOLUMN_NAME</B> String => primary key column name
2195             *	<LI><B>FKTABLE_CAT</B> String => foreign key table catalog (may be <code>null</code>)
2196             *      being exported (may be <code>null</code>)
2197             *	<LI><B>FKTABLE_SCHEM</B> String => foreign key table schema (may be <code>null</code>)
2198             *      being exported (may be <code>null</code>)
2199             *	<LI><B>FKTABLE_NAME</B> String => foreign key table name
2200             *      being exported
2201             *	<LI><B>FKCOLUMN_NAME</B> String => foreign key column name
2202             *      being exported
2203             *	<LI><B>KEY_SEQ</B> short => sequence number within foreign key( a value
2204             *  of 1 represents the first column of the foreign key, a value of 2 would
2205             *  represent the second column within the foreign key).
2206             *	<LI><B>UPDATE_RULE</B> short => What happens to 
2207             *       foreign key when primary is updated:
2208             *      <UL>
2209             *      <LI> importedNoAction - do not allow update of primary 
2210             *               key if it has been imported
2211             *      <LI> importedKeyCascade - change imported key to agree 
2212             *               with primary key update
2213             *      <LI> importedKeySetNull - change imported key to <code>NULL</code> if 
2214             *               its primary key has been updated
2215             *      <LI> importedKeySetDefault - change imported key to default values 
2216             *               if its primary key has been updated
2217             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2218             *                                 (for ODBC 2.x compatibility)
2219             *      </UL>
2220             *	<LI><B>DELETE_RULE</B> short => What happens to 
2221             *      the foreign key when primary is deleted.
2222             *      <UL>
2223             *      <LI> importedKeyNoAction - do not allow delete of primary 
2224             *               key if it has been imported
2225             *      <LI> importedKeyCascade - delete rows that import a deleted key
2226             *      <LI> importedKeySetNull - change imported key to <code>NULL</code> if 
2227             *               its primary key has been deleted
2228             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2229             *                                 (for ODBC 2.x compatibility)
2230             *      <LI> importedKeySetDefault - change imported key to default if 
2231             *               its primary key has been deleted
2232             *      </UL>
2233             *	<LI><B>FK_NAME</B> String => foreign key name (may be <code>null</code>)
2234             *	<LI><B>PK_NAME</B> String => primary key name (may be <code>null</code>)
2235             *	<LI><B>DEFERRABILITY</B> short => can the evaluation of foreign key 
2236             *      constraints be deferred until commit
2237             *      <UL>
2238             *      <LI> importedKeyInitiallyDeferred - see SQL92 for definition
2239             *      <LI> importedKeyInitiallyImmediate - see SQL92 for definition 
2240             *      <LI> importedKeyNotDeferrable - see SQL92 for definition 
2241             *      </UL>
2242             *  </OL>
2243             *
2244             * @param catalog a catalog name; must match the catalog name as it
2245             *        is stored in this database; "" retrieves those without a catalog;
2246             *        <code>null</code> means that the catalog name should not be used to narrow
2247             *        the search
2248             * @param schema a schema name; must match the schema name
2249             *        as it is stored in the database; "" retrieves those without a schema;
2250             *        <code>null</code> means that the schema name should not be used to narrow
2251             *        the search
2252             * @param table a table name; must match the table name as it is stored 
2253             *        in this database 
2254             * @return a <code>ResultSet</code> object in which each row is a 
2255             *         foreign key column description 
2256             * @exception SQLException if a database access error occurs
2257             * @see #getImportedKeys 
2258             */
2259            ResultSet getExportedKeys(String catalog, String schema,
2260                    String table) throws SQLException;
2261
2262            /**
2263             * Retrieves a description of the foreign key columns in the given foreign key
2264             * 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).
2265             * The number of columns returned from the parent table must match the number of
2266             * columns that make up the foreign key.  They
2267             * are ordered by FKTABLE_CAT, FKTABLE_SCHEM, FKTABLE_NAME, and
2268             * KEY_SEQ.
2269             *
2270             * <P>Each foreign key column description has the following columns:
2271             *  <OL>
2272             *	<LI><B>PKTABLE_CAT</B> String => parent key table catalog (may be <code>null</code>)
2273             *	<LI><B>PKTABLE_SCHEM</B> String => parent key table schema (may be <code>null</code>)
2274             *	<LI><B>PKTABLE_NAME</B> String => parent key table name
2275             *	<LI><B>PKCOLUMN_NAME</B> String => parent key column name
2276             *	<LI><B>FKTABLE_CAT</B> String => foreign key table catalog (may be <code>null</code>)
2277             *      being exported (may be <code>null</code>)
2278             *	<LI><B>FKTABLE_SCHEM</B> String => foreign key table schema (may be <code>null</code>)
2279             *      being exported (may be <code>null</code>)
2280             *	<LI><B>FKTABLE_NAME</B> String => foreign key table name
2281             *      being exported
2282             *	<LI><B>FKCOLUMN_NAME</B> String => foreign key column name
2283             *      being exported
2284             *	<LI><B>KEY_SEQ</B> short => sequence number within foreign key( a value
2285             *  of 1 represents the first column of the foreign key, a value of 2 would
2286             *  represent the second column within the foreign key).
2287             *	<LI><B>UPDATE_RULE</B> short => What happens to 
2288             *       foreign key when parent key is updated:
2289             *      <UL>
2290             *      <LI> importedNoAction - do not allow update of parent 
2291             *               key if it has been imported
2292             *      <LI> importedKeyCascade - change imported key to agree 
2293             *               with parent key update
2294             *      <LI> importedKeySetNull - change imported key to <code>NULL</code> if 
2295             *               its parent key has been updated
2296             *      <LI> importedKeySetDefault - change imported key to default values 
2297             *               if its parent key has been updated
2298             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2299             *                                 (for ODBC 2.x compatibility)
2300             *      </UL>
2301             *	<LI><B>DELETE_RULE</B> short => What happens to 
2302             *      the foreign key when parent key is deleted.
2303             *      <UL>
2304             *      <LI> importedKeyNoAction - do not allow delete of parent 
2305             *               key if it has been imported
2306             *      <LI> importedKeyCascade - delete rows that import a deleted key
2307             *      <LI> importedKeySetNull - change imported key to <code>NULL</code> if 
2308             *               its primary key has been deleted
2309             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2310             *                                 (for ODBC 2.x compatibility)
2311             *      <LI> importedKeySetDefault - change imported key to default if 
2312             *               its parent key has been deleted
2313             *      </UL>
2314             *	<LI><B>FK_NAME</B> String => foreign key name (may be <code>null</code>)
2315             *	<LI><B>PK_NAME</B> String => parent key name (may be <code>null</code>)
2316             *	<LI><B>DEFERRABILITY</B> short => can the evaluation of foreign key 
2317             *      constraints be deferred until commit
2318             *      <UL>
2319             *      <LI> importedKeyInitiallyDeferred - see SQL92 for definition
2320             *      <LI> importedKeyInitiallyImmediate - see SQL92 for definition 
2321             *      <LI> importedKeyNotDeferrable - see SQL92 for definition 
2322             *      </UL>
2323             *  </OL>
2324             *
2325             * @param parentCatalog a catalog name; must match the catalog name
2326             * as it is stored in the database; "" retrieves those without a
2327             * catalog; <code>null</code> means drop catalog name from the selection criteria 
2328             * @param parentSchema a schema name; must match the schema name as
2329             * it is stored in the database; "" retrieves those without a schema;
2330             * <code>null</code> means drop schema name from the selection criteria 
2331             * @param parentTable the name of the table that exports the key; must match
2332             * the table name as it is stored in the database
2333             * @param foreignCatalog a catalog name; must match the catalog name as
2334             * it is stored in the database; "" retrieves those without a
2335             * catalog; <code>null</code> means drop catalog name from the selection criteria
2336             * @param foreignSchema a schema name; must match the schema name as it
2337             * is stored in the database; "" retrieves those without a schema;
2338             * <code>null</code> means drop schema name from the selection criteria 
2339             * @param foreignTable the name of the table that imports the key; must match
2340             * the table name as it is stored in the database
2341             * @return <code>ResultSet</code> - each row is a foreign key column description 
2342             * @exception SQLException if a database access error occurs
2343             * @see #getImportedKeys 
2344             */
2345            ResultSet getCrossReference(String parentCatalog,
2346                    String parentSchema, String parentTable,
2347                    String foreignCatalog, String foreignSchema,
2348                    String foreignTable) throws SQLException;
2349
2350            /**
2351             * Retrieves a description of all the data types supported by
2352             * this database. They are ordered by DATA_TYPE and then by how
2353             * closely the data type maps to the corresponding JDBC SQL type.
2354             *
2355             * <P>If the database supports SQL distinct types, then getTypeInfo() will return
2356             * a single row with a TYPE_NAME of DISTINCT and a DATA_TYPE of Types.DISTINCT.
2357             * If the database supports SQL structured types, then getTypeInfo() will return
2358             * a single row with a TYPE_NAME of STRUCT and a DATA_TYPE of Types.STRUCT.
2359             *
2360             * <P>If SQL distinct or structured types are supported, then information on the
2361             * individual types may be obtained from the getUDTs() method.
2362             *
2363
2364             *
2365             * <P>Each type description has the following columns:
2366             *  <OL>
2367             *	<LI><B>TYPE_NAME</B> String => Type name
2368             *	<LI><B>DATA_TYPE</B> int => SQL data type from java.sql.Types
2369             *	<LI><B>PRECISION</B> int => maximum precision
2370             *	<LI><B>LITERAL_PREFIX</B> String => prefix used to quote a literal 
2371             *      (may be <code>null</code>)
2372             *	<LI><B>LITERAL_SUFFIX</B> String => suffix used to quote a literal 
2373             (may be <code>null</code>)
2374             *	<LI><B>CREATE_PARAMS</B> String => parameters used in creating 
2375             *      the type (may be <code>null</code>)
2376             *	<LI><B>NULLABLE</B> short => can you use NULL for this type.
2377             *      <UL>
2378             *      <LI> typeNoNulls - does not allow NULL values
2379             *      <LI> typeNullable - allows NULL values
2380             *      <LI> typeNullableUnknown - nullability unknown
2381             *      </UL>
2382             *	<LI><B>CASE_SENSITIVE</B> boolean=> is it case sensitive.
2383             *	<LI><B>SEARCHABLE</B> short => can you use "WHERE" based on this type:
2384             *      <UL>
2385             *      <LI> typePredNone - No support
2386             *      <LI> typePredChar - Only supported with WHERE .. LIKE
2387             *      <LI> typePredBasic - Supported except for WHERE .. LIKE
2388             *      <LI> typeSearchable - Supported for all WHERE ..
2389             *      </UL>
2390             *	<LI><B>UNSIGNED_ATTRIBUTE</B> boolean => is it unsigned.
2391             *	<LI><B>FIXED_PREC_SCALE</B> boolean => can it be a money value.
2392             *	<LI><B>AUTO_INCREMENT</B> boolean => can it be used for an 
2393             *      auto-increment value.
2394             *	<LI><B>LOCAL_TYPE_NAME</B> String => localized version of type name 
2395             *      (may be <code>null</code>)
2396             *	<LI><B>MINIMUM_SCALE</B> short => minimum scale supported
2397             *	<LI><B>MAXIMUM_SCALE</B> short => maximum scale supported
2398             *	<LI><B>SQL_DATA_TYPE</B> int => unused
2399             *	<LI><B>SQL_DATETIME_SUB</B> int => unused
2400             *	<LI><B>NUM_PREC_RADIX</B> int => usually 2 or 10
2401             *  </OL>
2402             *
2403             * <p>The PRECISION column represents the maximum column size that the server supports for the given datatype. 
2404             * For numeric data, this is the maximum precision.  For character data, this is the length in characters. 
2405             * For datetime datatypes, this is the length in characters of the String representation (assuming the 
2406             * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype, 
2407             * this is the length in bytes. Null is returned for data types where the
2408             * column size is not applicable.
2409             *   
2410             * @return a <code>ResultSet</code> object in which each row is an SQL 
2411             *         type description 
2412             * @exception SQLException if a database access error occurs
2413             */
2414            ResultSet getTypeInfo() throws SQLException;
2415
2416            /**
2417             * Indicates that a <code>NULL</code> value is NOT allowed for this
2418             * data type.
2419             * <P>
2420             * A possible value for column <code>NULLABLE</code> in the
2421             * <code>ResultSet</code> object returned by the method
2422             * <code>getTypeInfo</code>.
2423             */
2424            int typeNoNulls = 0;
2425
2426            /**
2427             * Indicates that a <code>NULL</code> value is allowed for this
2428             * data type.
2429             * <P>
2430             * A possible value for column <code>NULLABLE</code> in the
2431             * <code>ResultSet</code> object returned by the method
2432             * <code>getTypeInfo</code>.
2433             */
2434            int typeNullable = 1;
2435
2436            /**
2437             * Indicates that it is not known whether a <code>NULL</code> value 
2438             * is allowed for this data type.
2439             * <P>
2440             * A possible value for column <code>NULLABLE</code> in the
2441             * <code>ResultSet</code> object returned by the method
2442             * <code>getTypeInfo</code>.
2443             */
2444            int typeNullableUnknown = 2;
2445
2446            /**
2447             * Indicates that <code>WHERE</code> search clauses are not supported
2448             * for this type.
2449             * <P>
2450             * A possible value for column <code>SEARCHABLE</code> in the
2451             * <code>ResultSet</code> object returned by the method
2452             * <code>getTypeInfo</code>.
2453             */
2454            int typePredNone = 0;
2455
2456            /**
2457             * Indicates that the data type 
2458             * can be only be used in <code>WHERE</code> search clauses 
2459             * that  use <code>LIKE</code> predicates.
2460             * <P>
2461             * A possible value for column <code>SEARCHABLE</code> in the
2462             * <code>ResultSet</code> object returned by the method
2463             * <code>getTypeInfo</code>.
2464             */
2465            int typePredChar = 1;
2466
2467            /**
2468             * Indicates that the data type can be only be used in <code>WHERE</code> 
2469             * search clauses 
2470             * that do not use <code>LIKE</code> predicates.
2471             * <P>
2472             * A possible value for column <code>SEARCHABLE</code> in the
2473             * <code>ResultSet</code> object returned by the method
2474             * <code>getTypeInfo</code>.
2475             */
2476            int typePredBasic = 2;
2477
2478            /**
2479             * Indicates that all <code>WHERE</code> search clauses can be 
2480             * based on this type.
2481             * <P>
2482             * A possible value for column <code>SEARCHABLE</code> in the
2483             * <code>ResultSet</code> object returned by the method
2484             * <code>getTypeInfo</code>.
2485             */
2486            int typeSearchable = 3;
2487
2488            /**
2489             * Retrieves a description of the given table's indices and statistics. They are
2490             * ordered by NON_UNIQUE, TYPE, INDEX_NAME, and ORDINAL_POSITION.
2491             *
2492             * <P>Each index column description has the following columns:
2493             *  <OL>
2494             *	<LI><B>TABLE_CAT</B> String => table catalog (may be <code>null</code>)
2495             *	<LI><B>TABLE_SCHEM</B> String => table schema (may be <code>null</code>)
2496             *	<LI><B>TABLE_NAME</B> String => table name
2497             *	<LI><B>NON_UNIQUE</B> boolean => Can index values be non-unique. 
2498             *      false when TYPE is tableIndexStatistic
2499             *	<LI><B>INDEX_QUALIFIER</B> String => index catalog (may be <code>null</code>); 
2500             *      <code>null</code> when TYPE is tableIndexStatistic
2501             *	<LI><B>INDEX_NAME</B> String => index name; <code>null</code> when TYPE is 
2502             *      tableIndexStatistic
2503             *	<LI><B>TYPE</B> short => index type:
2504             *      <UL>
2505             *      <LI> tableIndexStatistic - this identifies table statistics that are
2506             *           returned in conjuction with a table's index descriptions
2507             *      <LI> tableIndexClustered - this is a clustered index
2508             *      <LI> tableIndexHashed - this is a hashed index
2509             *      <LI> tableIndexOther - this is some other style of index
2510             *      </UL>
2511             *	<LI><B>ORDINAL_POSITION</B> short => column sequence number 
2512             *      within index; zero when TYPE is tableIndexStatistic
2513             *	<LI><B>COLUMN_NAME</B> String => column name; <code>null</code> when TYPE is 
2514             *      tableIndexStatistic
2515             *	<LI><B>ASC_OR_DESC</B> String => column sort sequence, "A" => ascending, 
2516             *      "D" => descending, may be <code>null</code> if sort sequence is not supported; 
2517             *      <code>null</code> when TYPE is tableIndexStatistic	
2518             *	<LI><B>CARDINALITY</B> int => When TYPE is tableIndexStatistic, then 
2519             *      this is the number of rows in the table; otherwise, it is the 
2520             *      number of unique values in the index.
2521             *	<LI><B>PAGES</B> int => When TYPE is  tableIndexStatisic then 
2522             *      this is the number of pages used for the table, otherwise it 
2523             *      is the number of pages used for the current index.
2524             *	<LI><B>FILTER_CONDITION</B> String => Filter condition, if any.  
2525             *      (may be <code>null</code>)
2526             *  </OL>
2527             *
2528             * @param catalog a catalog name; must match the catalog name as it
2529             *        is stored in this database; "" retrieves those without a catalog;
2530             *        <code>null</code> means that the catalog name should not be used to narrow
2531             *        the search
2532             * @param schema a schema name; must match the schema name
2533             *        as it is stored in this database; "" retrieves those without a schema;
2534             *        <code>null</code> means that the schema name should not be used to narrow
2535             *        the search
2536             * @param table a table name; must match the table name as it is stored 
2537             *        in this database 
2538             * @param unique when true, return only indices for unique values; 
2539             *     when false, return indices regardless of whether unique or not 
2540             * @param approximate when true, result is allowed to reflect approximate 
2541             *     or out of data values; when false, results are requested to be 
2542             *     accurate
2543             * @return <code>ResultSet</code> - each row is an index column description 
2544             * @exception SQLException if a database access error occurs
2545             */
2546            ResultSet getIndexInfo(String catalog, String schema, String table,
2547                    boolean unique, boolean approximate) throws SQLException;
2548
2549            /**
2550             * Indicates that this column contains table statistics that
2551             * are returned in conjunction with a table's index descriptions.
2552             * <P>
2553             * A possible value for column <code>TYPE</code> in the
2554             * <code>ResultSet</code> object returned by the method
2555             * <code>getIndexInfo</code>.
2556             */
2557            short tableIndexStatistic = 0;
2558
2559            /**
2560             * Indicates that this table index is a clustered index.
2561             * <P>
2562             * A possible value for column <code>TYPE</code> in the
2563             * <code>ResultSet</code> object returned by the method
2564             * <code>getIndexInfo</code>.
2565             */
2566            short tableIndexClustered = 1;
2567
2568            /**
2569             * Indicates that this table index is a hashed index.
2570             * <P>
2571             * A possible value for column <code>TYPE</code> in the
2572             * <code>ResultSet</code> object returned by the method
2573             * <code>getIndexInfo</code>.
2574             */
2575            short tableIndexHashed = 2;
2576
2577            /**
2578             * Indicates that this table index is not a clustered
2579             * index, a hashed index, or table statistics;
2580             * it is something other than these.
2581             * <P>
2582             * A possible value for column <code>TYPE</code> in the
2583             * <code>ResultSet</code> object returned by the method
2584             * <code>getIndexInfo</code>.
2585             */
2586            short tableIndexOther = 3;
2587
2588            //--------------------------JDBC 2.0-----------------------------
2589
2590            /**
2591             * Retrieves whether this database supports the given result set type.
2592             *
2593             * @param type defined in <code>java.sql.ResultSet</code>
2594             * @return <code>true</code> if so; <code>false</code> otherwise 
2595             * @exception SQLException if a database access error occurs
2596             * @see Connection
2597             * @since 1.2
2598             */
2599            boolean supportsResultSetType(int type) throws SQLException;
2600
2601            /**
2602             * Retrieves whether this database supports the given concurrency type 
2603             * in combination with the given result set type.
2604             *
2605             * @param type defined in <code>java.sql.ResultSet</code>
2606             * @param concurrency type defined in <code>java.sql.ResultSet</code>
2607             * @return <code>true</code> if so; <code>false</code> otherwise 
2608             * @exception SQLException if a database access error occurs
2609             * @see Connection
2610             * @since 1.2
2611             */
2612            boolean supportsResultSetConcurrency(int type, int concurrency)
2613                    throws SQLException;
2614
2615            /**
2616             *
2617             * Retrieves whether for the given type of <code>ResultSet</code> object,
2618             * the result set's own updates are visible.
2619             *
2620             * @param type the <code>ResultSet</code> type; one of
2621             *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
2622             *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
2623             *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
2624             * @return <code>true</code> if updates are visible for the given result set type;
2625             *        <code>false</code> otherwise
2626             * @exception SQLException if a database access error occurs
2627             * @since 1.2
2628             */
2629            boolean ownUpdatesAreVisible(int type) throws SQLException;
2630
2631            /**
2632             * Retrieves whether a result set's own deletes are visible.
2633             *
2634             * @param type the <code>ResultSet</code> type; one of
2635             *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
2636             *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
2637             *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
2638             * @return <code>true</code> if deletes are visible for the given result set type;
2639             *        <code>false</code> otherwise
2640             * @exception SQLException if a database access error occurs
2641             * @since 1.2
2642             */
2643            boolean ownDeletesAreVisible(int type) throws SQLException;
2644
2645            /**
2646             * Retrieves whether a result set's own inserts are visible.
2647             *
2648             * @param type the <code>ResultSet</code> type; one of
2649             *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
2650             *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
2651             *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
2652             * @return <code>true</code> if inserts are visible for the given result set type;
2653             *        <code>false</code> otherwise
2654             * @exception SQLException if a database access error occurs
2655             * @since 1.2
2656             */
2657            boolean ownInsertsAreVisible(int type) throws SQLException;
2658
2659            /**
2660             * Retrieves whether updates made by others are visible.
2661             *
2662             * @param type the <code>ResultSet</code> type; one of
2663             *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
2664             *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
2665             *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
2666             * @return <code>true</code> if updates made by others
2667             *        are visible for the given result set type;
2668             *        <code>false</code> otherwise
2669             * @exception SQLException if a database access error occurs
2670             * @since 1.2
2671             */
2672            boolean othersUpdatesAreVisible(int type) throws SQLException;
2673
2674            /**
2675             * Retrieves whether deletes made by others are visible.
2676             *
2677             * @param type the <code>ResultSet</code> type; one of
2678             *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
2679             *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
2680             *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
2681             * @return <code>true</code> if deletes made by others
2682             *        are visible for the given result set type;
2683             *        <code>false</code> otherwise
2684             * @exception SQLException if a database access error occurs
2685             * @since 1.2
2686             */
2687            boolean othersDeletesAreVisible(int type) throws SQLException;
2688
2689            /**
2690             * Retrieves whether inserts made by others are visible.
2691             *
2692             * @param type the <code>ResultSet</code> type; one of
2693             *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
2694             *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
2695             *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
2696             * @return <code>true</code> if inserts made by others
2697             *         are visible for the given result set type;
2698             *         <code>false</code> otherwise
2699             * @exception SQLException if a database access error occurs
2700             * @since 1.2
2701             */
2702            boolean othersInsertsAreVisible(int type) throws SQLException;
2703
2704            /**
2705             * Retrieves whether or not a visible row update can be detected by 
2706             * calling the method <code>ResultSet.rowUpdated</code>.
2707             *
2708             * @param type the <code>ResultSet</code> type; one of
2709             *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
2710             *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
2711             *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
2712             * @return <code>true</code> if changes are detected by the result set type;
2713             *         <code>false</code> otherwise
2714             * @exception SQLException if a database access error occurs
2715             * @since 1.2
2716             */
2717            boolean updatesAreDetected(int type) throws SQLException;
2718
2719            /**
2720             * Retrieves whether or not a visible row delete can be detected by 
2721             * calling the method <code>ResultSet.rowDeleted</code>.  If the method
2722             * <code>deletesAreDetected</code> returns <code>false</code>, it means that
2723             * deleted rows are removed from the result set.
2724             *
2725             * @param type the <code>ResultSet</code> type; one of
2726             *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
2727             *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
2728             *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
2729             * @return <code>true</code> if deletes are detected by the given result set type;
2730             *         <code>false</code> otherwise
2731             * @exception SQLException if a database access error occurs
2732             * @since 1.2
2733             */
2734            boolean deletesAreDetected(int type) throws SQLException;
2735
2736            /**
2737             * Retrieves whether or not a visible row insert can be detected
2738             * by calling the method <code>ResultSet.rowInserted</code>.
2739             *
2740             * @param type the <code>ResultSet</code> type; one of
2741             *        <code>ResultSet.TYPE_FORWARD_ONLY</code>,
2742             *        <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>, or
2743             *        <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
2744             * @return <code>true</code> if changes are detected by the specified result
2745             *         set type; <code>false</code> otherwise
2746             * @exception SQLException if a database access error occurs
2747             * @since 1.2
2748             */
2749            boolean insertsAreDetected(int type) throws SQLException;
2750
2751            /**
2752             * Retrieves whether this database supports batch updates.
2753             *
2754             * @return <code>true</code> if this database supports batch upcates;
2755             *         <code>false</code> otherwise
2756             * @exception SQLException if a database access error occurs
2757             * @since 1.2
2758             */
2759            boolean supportsBatchUpdates() throws SQLException;
2760
2761            /**
2762             * Retrieves a description of the user-defined types (UDTs) defined 
2763             * in a particular schema.  Schema-specific UDTs may have type 
2764             * <code>JAVA_OBJECT</code>, <code>STRUCT</code>, 
2765             * or <code>DISTINCT</code>.
2766             *
2767             * <P>Only types matching the catalog, schema, type name and type  
2768             * criteria are returned.  They are ordered by <code>DATA_TYPE</code>, 
2769             * <code>TYPE_CAT</code>, <code>TYPE_SCHEM</code>  and  
2770             * <code>TYPE_NAME</code>.  The type name parameter may be a fully-qualified 
2771             * name.  In this case, the catalog and schemaPattern parameters are
2772             * ignored.
2773             *
2774             * <P>Each type description has the following columns:
2775             *  <OL>
2776             *	<LI><B>TYPE_CAT</B> String => the type's catalog (may be <code>null</code>)
2777             *	<LI><B>TYPE_SCHEM</B> String => type's schema (may be <code>null</code>)
2778             *	<LI><B>TYPE_NAME</B> String => type name
2779             *  <LI><B>CLASS_NAME</B> String => Java class name
2780             *	<LI><B>DATA_TYPE</B> int => type value defined in java.sql.Types.  
2781             *     One of JAVA_OBJECT, STRUCT, or DISTINCT
2782             *	<LI><B>REMARKS</B> String => explanatory comment on the type
2783             *  <LI><B>BASE_TYPE</B> short => type code of the source type of a 
2784             *     DISTINCT type or the type that implements the user-generated
2785             *     reference type of the SELF_REFERENCING_COLUMN of a structured
2786             *     type as defined in java.sql.Types (<code>null</code> if DATA_TYPE is not
2787             *     DISTINCT or not STRUCT with REFERENCE_GENERATION = USER_DEFINED) 
2788             *  </OL>
2789             *
2790             * <P><B>Note:</B> If the driver does not support UDTs, an empty
2791             * result set is returned.
2792             *
2793             * @param catalog a catalog name; must match the catalog name as it
2794             *        is stored in the database; "" retrieves those without a catalog;
2795             *        <code>null</code> means that the catalog name should not be used to narrow
2796             *        the search
2797             * @param schemaPattern a schema pattern name; must match the schema name
2798             *        as it is stored in the database; "" retrieves those without a schema;
2799             *        <code>null</code> means that the schema name should not be used to narrow
2800             *        the search
2801             * @param typeNamePattern a type name pattern; must match the type name
2802             *        as it is stored in the database; may be a fully qualified name 
2803             * @param types a list of user-defined types (JAVA_OBJECT, 
2804             *        STRUCT, or DISTINCT) to include; <code>null</code> returns all types 
2805             * @return <code>ResultSet</code> object in which each row describes a UDT
2806             * @exception SQLException if a database access error occurs
2807             * @see #getSearchStringEscape 
2808             * @since 1.2
2809             */
2810            ResultSet getUDTs(String catalog, String schemaPattern,
2811                    String typeNamePattern, int[] types) throws SQLException;
2812
2813            /**
2814             * Retrieves the connection that produced this metadata object.
2815             * <P>
2816             * @return the connection that produced this metadata object
2817             * @exception SQLException if a database access error occurs
2818             * @since 1.2
2819             */
2820            Connection getConnection() throws SQLException;
2821
2822            // ------------------- JDBC 3.0 -------------------------
2823
2824            /**
2825             * Retrieves whether this database supports savepoints.
2826             *
2827             * @return <code>true</code> if savepoints are supported; 
2828             *         <code>false</code> otherwise
2829             * @exception SQLException if a database access error occurs
2830             * @since 1.4
2831             */
2832            boolean supportsSavepoints() throws SQLException;
2833
2834            /**
2835             * Retrieves whether this database supports named parameters to callable 
2836             * statements.
2837             *
2838             * @return <code>true</code> if named parameters are supported; 
2839             *         <code>false</code> otherwise
2840             * @exception SQLException if a database access error occurs
2841             * @since 1.4
2842             */
2843            boolean supportsNamedParameters() throws SQLException;
2844
2845            /**
2846             * Retrieves whether it is possible to have multiple <code>ResultSet</code> objects
2847             * returned from a <code>CallableStatement</code> object
2848             * simultaneously.
2849             *
2850             * @return <code>true</code> if a <code>CallableStatement</code> object
2851             *         can return multiple <code>ResultSet</code> objects
2852             *         simultaneously; <code>false</code> otherwise
2853             * @exception SQLException if a datanase access error occurs
2854             * @since 1.4
2855             */
2856            boolean supportsMultipleOpenResults() throws SQLException;
2857
2858            /**
2859             * Retrieves whether auto-generated keys can be retrieved after 
2860             * a statement has been executed
2861             *
2862             * @return <code>true</code> if auto-generated keys can be retrieved
2863             *         after a statement has executed; <code>false</code> otherwise
2864             *<p>If <code>true</code> is returned, the JDBC driver must support the 
2865             * returning of auto-generated keys for at least SQL INSERT statements
2866             *<p>
2867             * @exception SQLException if a database access error occurs
2868             * @since 1.4
2869             */
2870            boolean supportsGetGeneratedKeys() throws SQLException;
2871
2872            /**
2873             * Retrieves a description of the user-defined type (UDT) hierarchies defined in a 
2874             * particular schema in this database. Only the immediate super type/ 
2875             * sub type relationship is modeled.
2876             * <P>
2877             * Only supertype information for UDTs matching the catalog, 
2878             * schema, and type name is returned. The type name parameter
2879             * may be a fully-qualified name. When the UDT name supplied is a 
2880             * fully-qualified name, the catalog and schemaPattern parameters are 
2881             * ignored. 
2882             * <P>
2883             * If a UDT does not have a direct super type, it is not listed here.
2884             * A row of the <code>ResultSet</code> object returned by this method
2885             * describes the designated UDT and a direct supertype. A row has the following 
2886             * columns:
2887             *  <OL>
2888             *  <LI><B>TYPE_CAT</B> String => the UDT's catalog (may be <code>null</code>)
2889             *  <LI><B>TYPE_SCHEM</B> String => UDT's schema (may be <code>null</code>)
2890             *  <LI><B>TYPE_NAME</B> String => type name of the UDT
2891             *  <LI><B>SUPERTYPE_CAT</B> String => the direct super type's catalog 
2892             *                           (may be <code>null</code>)
2893             *  <LI><B>SUPERTYPE_SCHEM</B> String => the direct super type's schema 
2894             *                             (may be <code>null</code>)
2895             *  <LI><B>SUPERTYPE_NAME</B> String => the direct super type's name
2896             *  </OL>
2897             *
2898             * <P><B>Note:</B> If the driver does not support type hierarchies, an 
2899             * empty result set is returned.
2900             *
2901             * @param catalog a catalog name; "" retrieves those without a catalog;
2902             *        <code>null</code> means drop catalog name from the selection criteria
2903             * @param schemaPattern a schema name pattern; "" retrieves those 
2904             *        without a schema
2905             * @param typeNamePattern a UDT name pattern; may be a fully-qualified
2906             *        name
2907             * @return a <code>ResultSet</code> object in which a row gives information
2908             *         about the designated UDT
2909             * @throws SQLException if a database access error occurs     
2910             * @see #getSearchStringEscape 
2911             * @since 1.4
2912             */
2913            ResultSet getSuperTypes(String catalog, String schemaPattern,
2914                    String typeNamePattern) throws SQLException;
2915
2916            /**
2917             * Retrieves a description of the table hierarchies defined in a particular 
2918             * schema in this database.
2919             *
2920             * <P>Only supertable information for tables matching the catalog, schema
2921             * and table name are returned. The table name parameter may be a fully-
2922             * qualified name, in which case, the catalog and schemaPattern parameters
2923             * are ignored. If a table does not have a super table, it is not listed here.
2924             * Supertables have to be defined in the same catalog and schema as the 
2925             * sub tables. Therefore, the type description does not need to include
2926             * this information for the supertable.
2927             *
2928             * <P>Each type description has the following columns:
2929             *  <OL>
2930             *  <LI><B>TABLE_CAT</B> String => the type's catalog (may be <code>null</code>)
2931             *  <LI><B>TABLE_SCHEM</B> String => type's schema (may be <code>null</code>)
2932             *  <LI><B>TABLE_NAME</B> String => type name
2933             *  <LI><B>SUPERTABLE_NAME</B> String => the direct super type's name
2934             *  </OL>
2935             *
2936             * <P><B>Note:</B> If the driver does not support type hierarchies, an 
2937             * empty result set is returned.
2938             *
2939             * @param catalog a catalog name; "" retrieves those without a catalog;
2940             *        <code>null</code> means drop catalog name from the selection criteria
2941             * @param schemaPattern a schema name pattern; "" retrieves those 
2942             *        without a schema
2943             * @param tableNamePattern a table name pattern; may be a fully-qualified
2944             *        name
2945             * @return a <code>ResultSet</code> object in which each row is a type description
2946             * @throws SQLException if a database access error occurs
2947             * @see #getSearchStringEscape 
2948             * @since 1.4
2949             */
2950            ResultSet getSuperTables(String catalog, String schemaPattern,
2951                    String tableNamePattern) throws SQLException;
2952
2953            /**
2954             * Indicates that <code>NULL</code> values might not be allowed.
2955             * <P>
2956             * A possible value for the column
2957             * <code>NULLABLE</code> in the <code>ResultSet</code> object
2958             * returned by the method <code>getAttributes</code>.
2959             */
2960            short attributeNoNulls = 0;
2961
2962            /**
2963             * Indicates that <code>NULL</code> values are definitely allowed.
2964             * <P>
2965             * A possible value for the column <code>NULLABLE</code>
2966             * in the <code>ResultSet</code> object
2967             * returned by the method <code>getAttributes</code>.
2968             */
2969            short attributeNullable = 1;
2970
2971            /**
2972             * Indicates that whether <code>NULL</code> values are allowed is not
2973             * known. 
2974             * <P>
2975             * A possible value for the column <code>NULLABLE</code>
2976             * in the <code>ResultSet</code> object
2977             * returned by the method <code>getAttributes</code>.
2978             */
2979            short attributeNullableUnknown = 2;
2980
2981            /**
2982             * Retrieves a description of the given attribute of the given type 
2983             * for a user-defined type (UDT) that is available in the given schema 
2984             * and catalog.
2985             * <P>
2986             * Descriptions are returned only for attributes of UDTs matching the 
2987             * catalog, schema, type, and attribute name criteria. They are ordered by
2988             * <code>TYPE_CAT</code>, <code>TYPE_SCHEM</code>, 
2989             * <code>TYPE_NAME</code> and <code>ORDINAL_POSITION</code>. This description
2990             * does not contain inherited attributes.
2991             * <P>
2992             * The <code>ResultSet</code> object that is returned has the following 
2993             * columns:
2994             * <OL>
2995             *  <LI><B>TYPE_CAT</B> String => type catalog (may be <code>null</code>)
2996             *	<LI><B>TYPE_SCHEM</B> String => type schema (may be <code>null</code>)
2997             *	<LI><B>TYPE_NAME</B> String => type name
2998             *	<LI><B>ATTR_NAME</B> String => attribute name
2999             *	<LI><B>DATA_TYPE</B> int => attribute type SQL type from java.sql.Types
3000             *	<LI><B>ATTR_TYPE_NAME</B> String => Data source dependent type name.
3001             *  For a UDT, the type name is fully qualified. For a REF, the type name is 
3002             *  fully qualified and represents the target type of the reference type.
3003             *	<LI><B>ATTR_SIZE</B> int => column size.  For char or date
3004             *	    types this is the maximum number of characters; for numeric or
3005             *	    decimal types this is precision.
3006             *	<LI><B>DECIMAL_DIGITS</B> int => the number of fractional digits. Null is returned for data types where  
3007             * DECIMAL_DIGITS is not applicable.
3008             *	<LI><B>NUM_PREC_RADIX</B> int => Radix (typically either 10 or 2)
3009             *	<LI><B>NULLABLE</B> int => whether NULL is allowed
3010             *      <UL>
3011             *      <LI> attributeNoNulls - might not allow NULL values
3012             *      <LI> attributeNullable - definitely allows NULL values
3013             *      <LI> attributeNullableUnknown - nullability unknown
3014             *      </UL>
3015             *	<LI><B>REMARKS</B> String => comment describing column (may be <code>null</code>)
3016             * 	<LI><B>ATTR_DEF</B> String => default value (may be <code>null</code>)
3017             *	<LI><B>SQL_DATA_TYPE</B> int => unused
3018             *	<LI><B>SQL_DATETIME_SUB</B> int => unused
3019             *	<LI><B>CHAR_OCTET_LENGTH</B> int => for char types the 
3020             *       maximum number of bytes in the column
3021             *	<LI><B>ORDINAL_POSITION</B> int	=> index of the attribute in the UDT  
3022             *      (starting at 1)
3023             *	<LI><B>IS_NULLABLE</B> String  => ISO rules are used to determine 
3024             * the nullability for a attribute.
3025             *       <UL>
3026             *       <LI> YES           --- if the attribute can include NULLs
3027             *       <LI> NO            --- if the attribute cannot include NULLs
3028             *       <LI> empty string  --- if the nullability for the 
3029             * attribute is unknown
3030             *       </UL>
3031             *  <LI><B>SCOPE_CATALOG</B> String => catalog of table that is the
3032             *      scope of a reference attribute (<code>null</code> if DATA_TYPE isn't REF)
3033             *  <LI><B>SCOPE_SCHEMA</B> String => schema of table that is the 
3034             *      scope of a reference attribute (<code>null</code> if DATA_TYPE isn't REF)
3035             *  <LI><B>SCOPE_TABLE</B> String => table name that is the scope of a 
3036             *      reference attribute (<code>null</code> if the DATA_TYPE isn't REF)
3037             * <LI><B>SOURCE_DATA_TYPE</B> short => source type of a distinct type or user-generated
3038             *      Ref type,SQL type from java.sql.Types (<code>null</code> if DATA_TYPE 
3039             *      isn't DISTINCT or user-generated REF)
3040             *  </OL>
3041             * @param catalog a catalog name; must match the catalog name as it
3042             *        is stored in the database; "" retrieves those without a catalog;
3043             *        <code>null</code> means that the catalog name should not be used to narrow
3044             *        the search
3045             * @param schemaPattern a schema name pattern; must match the schema name
3046             *        as it is stored in the database; "" retrieves those without a schema;
3047             *        <code>null</code> means that the schema name should not be used to narrow
3048             *        the search
3049             * @param typeNamePattern a type name pattern; must match the
3050             *        type name as it is stored in the database 
3051             * @param attributeNamePattern an attribute name pattern; must match the attribute
3052             *        name as it is declared in the database
3053             * @return a <code>ResultSet</code> object in which each row is an 
3054             *         attribute description
3055             * @exception SQLException if a database access error occurs
3056             * @see #getSearchStringEscape      
3057             * @since 1.4
3058             */
3059            ResultSet getAttributes(String catalog, String schemaPattern,
3060                    String typeNamePattern, String attributeNamePattern)
3061                    throws SQLException;
3062
3063            /**
3064             * Retrieves whether this database supports the given result set holdability.
3065             *
3066             * @param holdability one of the following constants:
3067             *          <code>ResultSet.HOLD_CURSORS_OVER_COMMIT</code> or
3068             *          <code>ResultSet.CLOSE_CURSORS_AT_COMMIT<code>
3069             * @return <code>true</code> if so; <code>false</code> otherwise 
3070             * @exception SQLException if a database access error occurs
3071             * @see Connection
3072             * @since 1.4
3073             */
3074            boolean supportsResultSetHoldability(int holdability)
3075                    throws SQLException;
3076
3077            /**
3078             * Retrieves this database's default holdability for <code>ResultSet</code>
3079             * objects.
3080             *
3081             * @return the default holdability; either 
3082             *         <code>ResultSet.HOLD_CURSORS_OVER_COMMIT</code> or
3083             *         <code>ResultSet.CLOSE_CURSORS_AT_COMMIT</code>
3084             * @exception SQLException if a database access error occurs
3085             * @since 1.4
3086             */
3087            int getResultSetHoldability() throws SQLException;
3088
3089            /**
3090             * Retrieves the major version number of the underlying database.
3091             *
3092             * @return the underlying database's major version
3093             * @exception SQLException if a database access error occurs
3094             * @since 1.4
3095             */
3096            int getDatabaseMajorVersion() throws SQLException;
3097
3098            /**
3099             * Retrieves the minor version number of the underlying database.
3100             *
3101             * @return underlying database's minor version
3102             * @exception SQLException if a database access error occurs
3103             * @since 1.4
3104             */
3105            int getDatabaseMinorVersion() throws SQLException;
3106
3107            /**
3108             * Retrieves the major JDBC version number for this
3109             * driver.
3110             * 
3111             * @return JDBC version major number
3112             * @exception SQLException if a database access error occurs
3113             * @since 1.4
3114             */
3115            int getJDBCMajorVersion() throws SQLException;
3116
3117            /**
3118             * Retrieves the minor JDBC version number for this
3119             * driver.
3120             * 
3121             * @return JDBC version minor number
3122             * @exception SQLException if a database access error occurs
3123             * @since 1.4
3124             */
3125            int getJDBCMinorVersion() throws SQLException;
3126
3127            /**
3128             *  A possible return value for the method 
3129             * <code>DatabaseMetaData.getSQLStateType</code> which is used to indicate
3130             * whether the value returned by the method 
3131             * <code>SQLException.getSQLState</code> is an 
3132             * X/Open (now know as Open Group) SQL CLI SQLSTATE value.
3133             * <P>
3134             * @since 1.4
3135             */
3136            int sqlStateXOpen = 1;
3137
3138            /**
3139             *  A possible return value for the method 
3140             * <code>DatabaseMetaData.getSQLStateType</code> which is used to indicate
3141             * whether the value returned by the method 
3142             * <code>SQLException.getSQLState</code> is an SQLSTATE value.
3143             * <P>
3144             * @since 1.6
3145             */
3146            int sqlStateSQL = 2;
3147
3148            /**
3149             *  A possible return value for the method 
3150             * <code>DatabaseMetaData.getSQLStateType</code> which is used to indicate
3151             * whether the value returned by the method 
3152             * <code>SQLException.getSQLState</code> is an SQL99 SQLSTATE value.
3153             * <P>
3154             * <b>Note:</b>This constant remains only for compatibility reasons. Developers
3155             * should use the constant <code>sqlStateSQL</code> instead.
3156             *
3157             * @since 1.4
3158             */
3159            int sqlStateSQL99 = sqlStateSQL;
3160
3161            /**
3162             * Indicates whether the SQLSTATE returned by <code>SQLException.getSQLState</code>
3163             * is X/Open (now known as Open Group) SQL CLI or SQL:2003.
3164             * @return the type of SQLSTATE; one of:
3165             *        sqlStateXOpen or
3166             *        sqlStateSQL
3167             * @throws SQLException if a database access error occurs 
3168             * @since 1.4
3169             */
3170            int getSQLStateType() throws SQLException;
3171
3172            /**
3173             * Indicates whether updates made to a LOB are made on a copy or directly 
3174             * to the LOB.
3175             * @return <code>true</code> if updates are made to a copy of the LOB;
3176             *         <code>false</code> if updates are made directly to the LOB
3177             * @throws SQLException if a database access error occurs
3178             * @since 1.4
3179             */
3180            boolean locatorsUpdateCopy() throws SQLException;
3181
3182            /**
3183             * Retrieves whether this database supports statement pooling.
3184             *
3185             * @return <code>true</code> if so; <code>false</code> otherwise
3186             * @throws SQLExcpetion if a database access error occurs
3187             * @since 1.4
3188             */
3189            boolean supportsStatementPooling() throws SQLException;
3190
3191            //------------------------- JDBC 4.0 -----------------------------------
3192
3193            /**
3194             * Indicates whether or not this data source supports the SQL <code>ROWID</code> type,
3195             * and if so  the lifetime for which a <code>RowId</code> object remains valid. 
3196             * <p>
3197             * The returned int values have the following relationship: 
3198             * <pre>
3199             *     ROWID_UNSUPPORTED < ROWID_VALID_OTHER < ROWID_VALID_TRANSACTION
3200             *         < ROWID_VALID_SESSION < ROWID_VALID_FOREVER
3201             * </pre>
3202             * so conditional logic such as 
3203             * <pre>
3204             *     if (metadata.getRowIdLifetime() > DatabaseMetaData.ROWID_VALID_TRANSACTION)
3205             * </pre>
3206             * can be used. Valid Forever means valid across all Sessions, and valid for 
3207             * a Session means valid across all its contained Transactions. 
3208             *
3209             * @return the status indicating the lifetime of a <code>RowId</code>
3210             * @throws SQLException if a database access error occurs
3211             * @since 1.6
3212             */
3213            RowIdLifetime getRowIdLifetime() throws SQLException;
3214
3215            /**
3216             * Retrieves the schema names available in this database.  The results
3217             * are ordered by <code>TABLE_CATALOG</code> and 
3218             * <code>TABLE_SCHEM</code>.
3219             *
3220             * <P>The schema columns are:
3221             *  <OL>
3222             *	<LI><B>TABLE_SCHEM</B> String => schema name
3223             *  <LI><B>TABLE_CATALOG</B> String => catalog name (may be <code>null</code>)
3224             *  </OL>
3225             *
3226             *
3227             * @param catalog a catalog name; must match the catalog name as it is stored
3228             * in the database;"" retrieves those without a catalog; null means catalog
3229             * name should not be used to narrow down the search.
3230             * @param schemaPattern a schema name; must match the schema name as it is
3231             * stored in the database; null means
3232             * schema name should not be used to narrow down the search.
3233             * @return a <code>ResultSet</code> object in which each row is a
3234             *         schema description
3235             * @exception SQLException if a database access error occurs
3236             * @see #getSearchStringEscape 
3237             * @since 1.6
3238             */
3239            ResultSet getSchemas(String catalog, String schemaPattern)
3240                    throws SQLException;
3241
3242            /**
3243             * Retrieves whether this database supports invoking user-defined or vendor functions 
3244             * using the stored procedure escape syntax.
3245             *
3246             * @return <code>true</code> if so; <code>false</code> otherwise 
3247             * @exception SQLException if a database access error occurs
3248             * @since 1.6
3249             */
3250            boolean supportsStoredFunctionsUsingCallSyntax()
3251                    throws SQLException;
3252
3253            /**
3254             * Retrieves whether a <code>SQLException</code> while autoCommit is <code>true</code> inidcates 
3255             * that all open ResultSets are closed, even ones that are holdable.  When a <code>SQLException</code> occurs while
3256             * autocommit is <code>true</code>, it is vendor specific whether the JDBC driver responds with a commit operation, a 
3257             * rollback operation, or by doing neither a commit nor a rollback.  A potential result of this difference
3258             * is in whether or not holdable ResultSets are closed.
3259             *
3260             * @return <code>true</code> if so; <code>false</code> otherwise 
3261             * @exception SQLException if a database access error occurs
3262             * @since 1.6
3263             */
3264            boolean autoCommitFailureClosesAllResultSets() throws SQLException;
3265
3266            /**
3267             * Retrieves a list of the client info properties 
3268             * that the driver supports.  The result set contains the following columns
3269             * <p>
3270             * <ol>
3271             * <li><b>NAME</b> String=> The name of the client info property<br>
3272             * <li><b>MAX_LEN</b> int=> The maximum length of the value for the property<br>
3273             * <li><b>DEFAULT_VALUE</b> String=> The default value of the property<br>
3274             * <li><b>DESCRIPTION</b> String=> A description of the property.  This will typically 
3275             * 						contain information as to where this property is 
3276             * 						stored in the database.
3277             * </ol>
3278             * <p>
3279             * The <code>ResultSet</code> is sorted by the NAME column
3280             * <p>
3281             * @return	A <code>ResultSet</code> object; each row is a supported client info
3282             * property
3283             * <p>
3284             *  @exception SQLException if a database access error occurs
3285             * <p>
3286             * @since 1.6
3287             */
3288            ResultSet getClientInfoProperties() throws SQLException;
3289
3290            /**
3291             * Retrieves a description of the  system and user functions available 
3292             * in the given catalog.
3293             * <P>
3294             * Only system and user function descriptions matching the schema and
3295             * function name criteria are returned.  They are ordered by
3296             * <code>FUNCTION_CAT</code>, <code>FUNCTION_SCHEM</code>,
3297             * <code>FUNCTION_NAME</code> and 
3298             * <code>SPECIFIC_ NAME</code>.
3299             *
3300             * <P>Each function description has the the following columns:
3301             *  <OL>
3302             *	<LI><B>FUNCTION_CAT</B> String => function catalog (may be <code>null</code>)
3303             *	<LI><B>FUNCTION_SCHEM</B> String => function schema (may be <code>null</code>)
3304             *	<LI><B>FUNCTION_NAME</B> String => function name.  This is the name 
3305             * used to invoke the function
3306             *	<LI><B>REMARKS</B> String => explanatory comment on the function
3307             * <LI><B>FUNCTION_TYPE</B> short => kind of function:
3308             *      <UL>
3309             *      <LI>functionResultUnknown - Cannot determine if a return value
3310             *       or table will be returned
3311             *      <LI> functionNoTable- Does not return a table
3312             *      <LI> functionReturnsTable - Returns a table
3313             *      </UL>
3314             *	<LI><B>SPECIFIC_NAME</B> String  => the name which uniquely identifies 
3315             *  this function within its schema.  This is a user specified, or DBMS
3316             * generated, name that may be different then the <code>FUNCTION_NAME</code> 
3317             * for example with overload functions
3318             *  </OL>
3319             * <p>
3320             * A user may not have permission to execute any of the functions that are
3321             * returned by <code>getFunctions</code>
3322             *
3323             * @param catalog a catalog name; must match the catalog name as it
3324             *        is stored in the database; "" retrieves those without a catalog;
3325             *        <code>null</code> means that the catalog name should not be used to narrow
3326             *        the search
3327             * @param schemaPattern a schema name pattern; must match the schema name
3328             *        as it is stored in the database; "" retrieves those without a schema;
3329             *        <code>null</code> means that the schema name should not be used to narrow
3330             *        the search
3331             * @param functionNamePattern a function name pattern; must match the
3332             *        function name as it is stored in the database 
3333             * @return <code>ResultSet</code> - each row is a function description 
3334             * @exception SQLException if a database access error occurs
3335             * @see #getSearchStringEscape 
3336             * @since 1.6
3337             */
3338            ResultSet getFunctions(String catalog, String schemaPattern,
3339                    String functionNamePattern) throws SQLException;
3340
3341            /**
3342             * Retrieves a description of the given catalog's system or user 
3343             * function parameters and return type.
3344             *
3345             * <P>Only descriptions matching the schema,  function and
3346             * parameter name criteria are returned. They are ordered by
3347             * <code>FUNCTION_CAT</code>, <code>FUNCTION_SCHEM</code>,
3348             * <code>FUNCTION_NAME</code> and 
3349             * <code>SPECIFIC_ NAME</code>. Within this, the return value,
3350             * if any, is first. Next are the parameter descriptions in call
3351             * order. The column descriptions follow in column number order.
3352             *
3353             * <P>Each row in the <code>ResultSet</code> 
3354             * is a parameter description, column description or
3355             * return type description with the following fields:
3356             *  <OL>
3357             *  <LI><B>FUNCTION_CAT</B> String => function catalog (may be <code>null</code>)
3358             *	<LI><B>FUNCTION_SCHEM</B> String => function schema (may be <code>null</code>)
3359             *	<LI><B>FUNCTION_NAME</B> String => function name.  This is the name 
3360             * used to invoke the function
3361             *	<LI><B>COLUMN_NAME</B> String => column/parameter name 
3362             *	<LI><B>COLUMN_TYPE</B> Short => kind of column/parameter:
3363             *      <UL>
3364             *      <LI> functionColumnUnknown - nobody knows
3365             *      <LI> functionColumnIn - IN parameter
3366             *      <LI> functionColumnInOut - INOUT parameter
3367             *      <LI> functionColumnOut - OUT parameter
3368             *      <LI> functionColumnReturn - function return value
3369             *      <LI> functionColumnResult - Indicates that the parameter or column
3370             *  is a column in the <code>ResultSet</code>
3371             *      </UL>
3372             *  <LI><B>DATA_TYPE</B> int => SQL type from java.sql.Types
3373             *	<LI><B>TYPE_NAME</B> String => SQL type name, for a UDT type the
3374             *  type name is fully qualified
3375             *	<LI><B>PRECISION</B> int => precision
3376             *	<LI><B>LENGTH</B> int => length in bytes of data
3377             *	<LI><B>SCALE</B> short => scale -  null is returned for data types where  
3378             * SCALE is not applicable.
3379             *	<LI><B>RADIX</B> short => radix
3380             *	<LI><B>NULLABLE</B> short => can it contain NULL.
3381             *      <UL>
3382             *      <LI> functionNoNulls - does not allow NULL values
3383             *      <LI> functionNullable - allows NULL values
3384             *      <LI> functionNullableUnknown - nullability unknown
3385             *      </UL>
3386             *	<LI><B>REMARKS</B> String => comment describing column/parameter
3387             *	<LI><B>CHAR_OCTET_LENGTH</B> int  => the maximum length of binary 
3388             * and character based parameters or columns.  For any other datatype the returned value 
3389             * is a NULL
3390             *	<LI><B>ORDINAL_POSITION</B> int  => the ordinal position, starting 
3391             * from 1, for the input and output parameters. A value of 0
3392             * is returned if this row describes the function's return value. 
3393             * For result set columns, it is the
3394             * ordinal position of the column in the result set starting from 1.  
3395             *	<LI><B>IS_NULLABLE</B> String  => ISO rules are used to determine 
3396             * the nullability for a parameter or column.
3397             *       <UL>
3398             *       <LI> YES           --- if the parameter or column can include NULLs
3399             *       <LI> NO            --- if the parameter or column  cannot include NULLs
3400             *       <LI> empty string  --- if the nullability for the 
3401             * parameter  or column is unknown
3402             *       </UL>
3403             *	<LI><B>SPECIFIC_NAME</B> String  => the name which uniquely identifies 
3404             * this function within its schema.  This is a user specified, or DBMS
3405             * generated, name that may be different then the <code>FUNCTION_NAME</code> 
3406             * for example with overload functions
3407             *  </OL>
3408             * 
3409             * <p>The PRECISION column represents the specified column size for the given 
3410             * parameter or column. 
3411             * For numeric data, this is the maximum precision.  For character data, this is the length in characters. 
3412             * For datetime datatypes, this is the length in characters of the String representation (assuming the 
3413             * maximum allowed precision of the fractional seconds component). For binary data, this is the length in bytes.  For the ROWID datatype, 
3414             * this is the length in bytes. Null is returned for data types where the
3415             * column size is not applicable.
3416             * @param catalog a catalog name; must match the catalog name as it
3417             *        is stored in the database; "" retrieves those without a catalog;
3418             *        <code>null</code> means that the catalog name should not be used to narrow
3419             *        the search
3420             * @param schemaPattern a schema name pattern; must match the schema name
3421             *        as it is stored in the database; "" retrieves those without a schema;
3422             *        <code>null</code> means that the schema name should not be used to narrow
3423             *        the search
3424             * @param functionNamePattern a procedure name pattern; must match the
3425             *        function name as it is stored in the database 
3426             * @param columnNamePattern a parameter name pattern; must match the 
3427             * parameter or column name as it is stored in the database 
3428             * @return <code>ResultSet</code> - each row describes a 
3429             * user function parameter, column  or return type
3430             *
3431             * @exception SQLException if a database access error occurs
3432             * @see #getSearchStringEscape 
3433             * @since 1.6
3434             */
3435            ResultSet getFunctionColumns(String catalog, String schemaPattern,
3436                    String functionNamePattern, String columnNamePattern)
3437                    throws SQLException;
3438
3439            /**
3440             * Indicates that type of the parameter or column is unknown.
3441             * <P>
3442             * A possible value for the column
3443             * <code>COLUMN_TYPE</code>
3444             * in the <code>ResultSet</code> 
3445             * returned by the method <code>getFunctionColumns</code>.
3446             */
3447            int functionColumnUnknown = 0;
3448
3449            /**
3450             * Indicates that the parameter or column is an IN parameter.
3451             * <P>
3452             *  A possible value for the column
3453             * <code>COLUMN_TYPE</code>
3454             * in the <code>ResultSet</code> 
3455             * returned by the method <code>getFunctionColumns</code>.
3456             * @since 1.6
3457             */
3458            int functionColumnIn = 1;
3459
3460            /**
3461             * Indicates that the parameter or column is an INOUT parameter.
3462             * <P>
3463             * A possible value for the column
3464             * <code>COLUMN_TYPE</code>
3465             * in the <code>ResultSet</code> 
3466             * returned by the method <code>getFunctionColumns</code>.     
3467             * @since 1.6
3468             */
3469            int functionColumnInOut = 2;
3470
3471            /**
3472             * Indicates that the parameter or column is an OUT parameter.
3473             * <P>
3474             * A possible value for the column
3475             * <code>COLUMN_TYPE</code>
3476             * in the <code>ResultSet</code> 
3477             * returned by the method <code>getFunctionColumns</code>.
3478             * @since 1.6
3479             */
3480            int functionColumnOut = 3;
3481            /**
3482             * Indicates that the parameter or column is a return value.
3483             * <P>
3484             *  A possible value for the column
3485             * <code>COLUMN_TYPE</code>
3486             * in the <code>ResultSet</code> 
3487             * returned by the method <code>getFunctionColumns</code>.     
3488             * @since 1.6
3489             */
3490            int functionReturn = 4;
3491
3492            /**
3493             * Indicates that the parameter or column is a column in a result set.
3494             * <P>
3495             *  A possible value for the column
3496             * <code>COLUMN_TYPE</code>
3497             * in the <code>ResultSet</code> 
3498             * returned by the method <code>getFunctionColumns</code>.     
3499             * @since 1.6
3500             */
3501            int functionColumnResult = 5;
3502
3503            /**
3504             * Indicates that <code>NULL</code> values are not allowed.
3505             * <P>
3506             * A possible value for the column
3507             * <code>NULLABLE</code>
3508             * in the <code>ResultSet</code> object
3509             * returned by the method <code>getFunctionColumns</code>.     
3510             * @since 1.6
3511             */
3512            int functionNoNulls = 0;
3513
3514            /**
3515             * Indicates that <code>NULL</code> values are allowed.
3516             * <P>
3517             * A possible value for the column
3518             * <code>NULLABLE</code>
3519             * in the <code>ResultSet</code> object
3520             * returned by the method <code>getFunctionColumns</code>.     
3521             * @since 1.6
3522             */
3523            int functionNullable = 1;
3524
3525            /**
3526             * Indicates that whether <code>NULL</code> values are allowed
3527             * is unknown.
3528             * <P>
3529             * A possible value for the column
3530             * <code>NULLABLE</code>
3531             * in the <code>ResultSet</code> object
3532             * returned by the method <code>getFunctionColumns</code>.    
3533             * @since 1.6
3534             */
3535            int functionNullableUnknown = 2;
3536
3537            /**
3538             * Indicates that it is not known whether the function returns
3539             * a result or a table.
3540             * <P>
3541             * A possible value for column <code>FUNCTION_TYPE</code> in the
3542             * <code>ResultSet</code> object returned by the method
3543             * <code>getFunctions</code>.
3544             * @since 1.6
3545             */
3546            int functionResultUnknown = 0;
3547
3548            /**
3549             * Indicates that the function  does not return a table.
3550             * <P>
3551             * A possible value for column <code>FUNCTION_TYPE</code> in the
3552             * <code>ResultSet</code> object returned by the method
3553             * <code>getFunctions</code>.
3554             * @since 1.6
3555             */
3556            int functionNoTable = 1;
3557
3558            /**
3559             * Indicates that the function  returns a table.
3560             * <P>
3561             * A possible value for column <code>FUNCTION_TYPE</code> in the
3562             * <code>ResultSet</code> object returned by the method
3563             * <code>getFunctions</code>.
3564             * @since 1.6
3565             */
3566            int functionReturnsTable = 2;
3567
3568        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.