Source Code Cross Referenced for tinySQLDatabaseMetaData.java in  » Database-DBMS » TinySQL » com » sqlmagic » tinysql » Java Source Code / Java DocumentationJava Source Code and Java Documentation

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 geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Database DBMS » TinySQL » com.sqlmagic.tinysql 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


0001:        /*
0002:         * tinySQLDatabaseMetaData.java
0003:         *
0004:         * This library is free software; you can redistribute it and/or
0005:         * modify it under the terms of the GNU Lesser General Public
0006:         * License as published by the Free Software Foundation; either
0007:         * version 2.1 of the License, or (at your option) any later version.
0008:         *
0009:         * This library is distributed in the hope that it will be useful,
0010:         * but WITHOUT ANY WARRANTY; without even the implied warranty of
0011:         * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
0012:         * Lesser General Public License for more details.
0013:         *
0014:         * You should have received a copy of the GNU Lesser General Public
0015:         * License along with this library; if not, write to the Free Software
0016:         * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
0017:         *
0018:         * $Author: davis $
0019:         * $Date: 2004/12/18 21:32:33 $
0020:         * $Revision: 1.1 $
0021:         */
0022:
0023:        /**
0024:         dBase read/write access <br> 
0025:         @author Brian Jepson <bjepson@home.com>
0026:         @author Marcel Ruff <ruff@swand.lake.de> Added write access to dBase and JDK 2 support
0027:         */package com.sqlmagic.tinysql;
0028:
0029:        /**
0030:         * Comprehensive information about the database as a whole.
0031:         *
0032:         * Many of the methods here return lists of information in 
0033:         * the form of ResultSet objects.
0034:         * You can use the normal ResultSet methods such as getString and getInt 
0035:         * to retrieve the data from these ResultSets.  If a given form of
0036:         * metadata is not available, these methods should throw an SQLException.
0037:         *
0038:         * Some of these methods take arguments that are String patterns.  These
0039:         * arguments all have names such as fooPattern.  Within a pattern String, "%"
0040:         * means match any substring of 0 or more characters, and "_" means match
0041:         * any one character. Only metadata entries matching the search pattern 
0042:         * are returned. If a search pattern argument is set to a null ref, 
0043:         * that argument's criteria will be dropped from the search.
0044:         * 
0045:         * An SQLException will be thrown if a driver does not support a meta
0046:         * data method.  In the case of methods that return a ResultSet,
0047:         * either a ResultSet (which may be empty) is returned or a
0048:         * SQLException is thrown.
0049:         */
0050:        import java.sql.SQLException;
0051:        import java.sql.Connection;
0052:        import java.sql.ResultSet;
0053:        import java.sql.Types;
0054:
0055:        public class tinySQLDatabaseMetaData implements 
0056:                java.sql.DatabaseMetaData {
0057:
0058:            /**
0059:             *
0060:             * The result set.
0061:             *
0062:             */
0063:            private Connection connection = null;
0064:
0065:            public tinySQLDatabaseMetaData(Connection connection) {
0066:                this .connection = connection;
0067:            }
0068:
0069:            //----------------------------------------------------------------------
0070:            // First, a variety of minor information about the target database.
0071:
0072:            /**
0073:             * Can all the procedures returned by getProcedures be called by the
0074:             * current user?
0075:             *
0076:             * @return <code>true</code> if so; <code>false</code> otherwise
0077:             * @exception SQLException if a database access error occurs
0078:             */
0079:            public boolean allProceduresAreCallable() {
0080:                return false;
0081:            }
0082:
0083:            /**
0084:             * Can all the tables returned by getTable be SELECTed by the
0085:             * current user?
0086:             *
0087:             * @return <code>true</code> if so; <code>false</code> otherwise 
0088:             * @exception SQLException if a database access error occurs
0089:             */
0090:            public boolean allTablesAreSelectable() {
0091:                return true;
0092:            }
0093:
0094:            /**
0095:             * What's the url for this database?
0096:             *
0097:             * @return the url or null if it cannot be generated
0098:             * @exception SQLException if a database access error occurs
0099:             */
0100:            public String getURL() {
0101:                return ""; // !!!
0102:            }
0103:
0104:            /**
0105:             * What's our user name as known to the database?
0106:             *
0107:             * @return our database user name
0108:             * @exception SQLException if a database access error occurs
0109:             */
0110:            public String getUserName() {
0111:                return "";
0112:            }
0113:
0114:            /**
0115:             * Is the database in read-only mode?
0116:             *
0117:             * @return <code>true</code> if so; <code>false</code> otherwise
0118:             * @exception SQLException if a database access error occurs
0119:             */
0120:            public boolean isReadOnly() {
0121:                return false;
0122:            }
0123:
0124:            /**
0125:             * Are NULL values sorted high?
0126:             *
0127:             * @return <code>true</code> if so; <code>false</code> otherwise
0128:             * @exception SQLException if a database access error occurs
0129:             */
0130:            public boolean nullsAreSortedHigh() {
0131:                return false;
0132:            }
0133:
0134:            /**
0135:             * Are NULL values sorted low?
0136:             *
0137:             * @return <code>true</code> if so; <code>false</code> otherwise
0138:             * @exception SQLException if a database access error occurs
0139:             */
0140:            public boolean nullsAreSortedLow() {
0141:                return !nullsAreSortedHigh();
0142:            }
0143:
0144:            /**
0145:             * Are NULL values sorted at the start regardless of sort order?
0146:             *
0147:             * @return <code>true</code> if so; <code>false</code> otherwise 
0148:             * @exception SQLException if a database access error occurs
0149:             */
0150:            public boolean nullsAreSortedAtStart() {
0151:                return false;
0152:            }
0153:
0154:            /**
0155:             * Are NULL values sorted at the end regardless of sort order?
0156:             *
0157:             * @return <code>true</code> if so; <code>false</code> otherwise
0158:             * @exception SQLException if a database access error occurs
0159:             */
0160:            public boolean nullsAreSortedAtEnd() {
0161:                return !nullsAreSortedAtStart();
0162:            }
0163:
0164:            /**
0165:             * What's the name of this database product?
0166:             *
0167:             * @return database product name
0168:             * @exception SQLException if a database access error occurs
0169:             */
0170:            public String getDatabaseProductName() {
0171:                return "tinySQL";
0172:            }
0173:
0174:            /**
0175:             * What's the version of this database product?
0176:             *
0177:             * @return database version
0178:             * @exception SQLException if a database access error occurs
0179:             */
0180:            public String getDatabaseProductVersion() {
0181:                return "dBase III";
0182:            }
0183:
0184:            /**
0185:             * What's the name of this JDBC driver?
0186:             *
0187:             * @return JDBC driver name
0188:             * @exception SQLException if a database access error occurs
0189:             */
0190:            public String getDriverName() {
0191:                return "com.sqlmagic.tinysql.dbfFileDriver";
0192:            }
0193:
0194:            /**
0195:             * What's the version of this JDBC driver?
0196:             *
0197:             * @return JDBC driver version
0198:             * @exception SQLException if a database access error occurs
0199:             */
0200:            public String getDriverVersion() {
0201:                return tinySQLGlobals.VERSION;
0202:            }
0203:
0204:            /**
0205:             * What's this JDBC driver's major version number?
0206:             *
0207:             * @return JDBC driver major version
0208:             */
0209:            public int getDriverMajorVersion() {
0210:                return 2;
0211:            }
0212:
0213:            /**
0214:             * What's this JDBC driver's minor version number?
0215:             *
0216:             * @return JDBC driver minor version number
0217:             */
0218:            public int getDriverMinorVersion() {
0219:                return 1;
0220:            }
0221:
0222:            /**
0223:             * Does the database store tables in a local file?
0224:             *
0225:             * @return <code>true</code> if so; <code>false</code> otherwise
0226:             * @exception SQLException if a database access error occurs
0227:             */
0228:            public boolean usesLocalFiles() {
0229:                return true;
0230:            }
0231:
0232:            /**
0233:             * Does the database use a file for each table?
0234:             *
0235:             * @return true if the database uses a local file for each table
0236:             * @exception SQLException if a database access error occurs
0237:             */
0238:            public boolean usesLocalFilePerTable() {
0239:                return true;
0240:            }
0241:
0242:            /**
0243:             * Does the database treat mixed case unquoted SQL identifiers as
0244:             * case sensitive and as a result store them in mixed case?
0245:             *
0246:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver will always return false.
0247:             *
0248:             * @return <code>true</code> if so; <code>false</code> otherwise 
0249:             * @exception SQLException if a database access error occurs
0250:             */
0251:            public boolean supportsMixedCaseIdentifiers() {
0252:                return false;
0253:            }
0254:
0255:            /**
0256:             * Does the database treat mixed case unquoted SQL identifiers as
0257:             * case insensitive and store them in upper case?
0258:             *
0259:             * @return <code>true</code> if so; <code>false</code> otherwise 
0260:             * @exception SQLException if a database access error occurs
0261:             */
0262:            public boolean storesUpperCaseIdentifiers() {
0263:                return true;
0264:            }
0265:
0266:            /**
0267:             * Does the database treat mixed case unquoted SQL identifiers as
0268:             * case insensitive and store them in lower case?
0269:             *
0270:             * @return <code>true</code> if so; <code>false</code> otherwise 
0271:             * @exception SQLException if a database access error occurs
0272:             */
0273:            public boolean storesLowerCaseIdentifiers() {
0274:                return !storesUpperCaseIdentifiers();
0275:            }
0276:
0277:            /**
0278:             * Does the database treat mixed case unquoted SQL identifiers as
0279:             * case insensitive and store them in mixed case?
0280:             *
0281:             * @return <code>true</code> if so; <code>false</code> otherwise 
0282:             * @exception SQLException if a database access error occurs
0283:             */
0284:            public boolean storesMixedCaseIdentifiers() {
0285:                return supportsMixedCaseIdentifiers();
0286:            }
0287:
0288:            /**
0289:             * Does the database treat mixed case quoted SQL identifiers as
0290:             * case sensitive and as a result store them in mixed case?
0291:             *
0292:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver will always return true.
0293:             *
0294:             * @return <code>true</code> if so; <code>false</code> otherwise
0295:             * @exception SQLException if a database access error occurs
0296:             */
0297:            public boolean supportsMixedCaseQuotedIdentifiers() {
0298:                return supportsMixedCaseIdentifiers();
0299:            }
0300:
0301:            /**
0302:             * Does the database treat mixed case quoted SQL identifiers as
0303:             * case insensitive and store them in upper case?
0304:             *
0305:             * @return <code>true</code> if so; <code>false</code> otherwise 
0306:             * @exception SQLException if a database access error occurs
0307:             */
0308:            public boolean storesUpperCaseQuotedIdentifiers() {
0309:                return true;
0310:            }
0311:
0312:            /**
0313:             * Does the database treat mixed case quoted SQL identifiers as
0314:             * case insensitive and store them in lower case?
0315:             *
0316:             * @return <code>true</code> if so; <code>false</code> otherwise 
0317:             * @exception SQLException if a database access error occurs
0318:             */
0319:            public boolean storesLowerCaseQuotedIdentifiers() {
0320:                return !storesUpperCaseQuotedIdentifiers();
0321:            }
0322:
0323:            /**
0324:             * Does the database treat mixed case quoted SQL identifiers as
0325:             * case insensitive and store them in mixed case?
0326:             *
0327:             * @return <code>true</code> if so; <code>false</code> otherwise 
0328:             * @exception SQLException if a database access error occurs
0329:             */
0330:            public boolean storesMixedCaseQuotedIdentifiers() {
0331:                return supportsMixedCaseIdentifiers();
0332:            }
0333:
0334:            /**
0335:             * What's the string used to quote SQL identifiers?
0336:             * This returns a space " " if identifier quoting isn't supported.
0337:             *
0338:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> 
0339:             * driver always uses a double quote character.
0340:             *
0341:             * @return the quoting string
0342:             * @exception SQLException if a database access error occurs
0343:             */
0344:            public String getIdentifierQuoteString() {
0345:                return "\""; // "'";
0346:            }
0347:
0348:            /**
0349:             * Gets a comma-separated list of all a database's SQL keywords
0350:             * that are NOT also SQL92 keywords.
0351:             *
0352:             * @return the list 
0353:             * @exception SQLException if a database access error occurs
0354:             */
0355:            public String getSQLKeywords() {
0356:                return "";
0357:            }
0358:
0359:            /**
0360:             * Gets a comma-separated list of math functions.  These are the 
0361:             * X/Open CLI math function names used in the JDBC function escape 
0362:             * clause.
0363:             *
0364:             * @return the list
0365:             * @exception SQLException if a database access error occurs
0366:             */
0367:            public String getNumericFunctions() {
0368:                return "";
0369:            }
0370:
0371:            /**
0372:             * Gets a comma-separated list of string functions.  These are the 
0373:             * X/Open CLI string function names used in the JDBC function escape 
0374:             * clause.
0375:             *
0376:             * @return the list
0377:             * @exception SQLException if a database access error occurs
0378:             */
0379:            public String getStringFunctions() {
0380:                return "";
0381:            }
0382:
0383:            /**
0384:             * Gets a comma-separated list of system functions.  These are the 
0385:             * X/Open CLI system function names used in the JDBC function escape 
0386:             * clause.
0387:             *
0388:             * @return the list
0389:             * @exception SQLException if a database access error occurs
0390:             */
0391:            public String getSystemFunctions() {
0392:                return "";
0393:            }
0394:
0395:            /**
0396:             * Gets a comma-separated list of time and date functions.
0397:             *
0398:             * @return the list
0399:             * @exception SQLException if a database access error occurs
0400:             */
0401:            public String getTimeDateFunctions() {
0402:                return "";
0403:            }
0404:
0405:            /**
0406:             * Gets the string that can be used to escape wildcard characters.
0407:             * This is the string that can be used to escape '_' or '%' in
0408:             * the string pattern style catalog search parameters.
0409:             *
0410:             * <P>The '_' character represents any single character.
0411:             * <P>The '%' character represents any sequence of zero or 
0412:             * more characters.
0413:             *
0414:             * @return the string used to escape wildcard characters
0415:             * @exception SQLException if a database access error occurs
0416:             */
0417:            public String getSearchStringEscape() {
0418:                return "\\";
0419:            }
0420:
0421:            /**
0422:             * Gets all the "extra" characters that can be used in unquoted
0423:             * identifier names (those beyond a-z, A-Z, 0-9 and _).
0424:             *
0425:             * @return the string containing the extra characters 
0426:             * @exception SQLException if a database access error occurs
0427:             */
0428:            public String getExtraNameCharacters() {
0429:                return "";
0430:            }
0431:
0432:            //--------------------------------------------------------------------
0433:            // Functions describing which features are supported.
0434:
0435:            /**
0436:             * Is "ALTER TABLE" with add column supported?
0437:             *
0438:             * @return <code>true</code> if so; <code>false</code> otherwise
0439:             * @exception SQLException if a database access error occurs
0440:             */
0441:            public boolean supportsAlterTableWithAddColumn() {
0442:                return true; // !!!
0443:            }
0444:
0445:            /**
0446:             * Is "ALTER TABLE" with drop column supported?
0447:             *
0448:             * @return <code>true</code> if so; <code>false</code> otherwise
0449:             * @exception SQLException if a database access error occurs
0450:             */
0451:            public boolean supportsAlterTableWithDropColumn() {
0452:                return true; // !!!
0453:            }
0454:
0455:            /**
0456:             * Is column aliasing supported? 
0457:             *
0458:             * <P>If so, the SQL AS clause can be used to provide names for
0459:             * computed columns or to provide alias names for columns as
0460:             * required.
0461:             *
0462:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0463:             *
0464:             * @return <code>true</code> if so; <code>false</code> otherwise 
0465:             * @exception SQLException if a database access error occurs
0466:             */
0467:            public boolean supportsColumnAliasing() {
0468:                return true;
0469:            }
0470:
0471:            /**
0472:             * Are concatenations between NULL and non-NULL values NULL?
0473:             *
0474:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0475:             *
0476:             * @return <code>true</code> if so; <code>false</code> otherwise
0477:             * @exception SQLException if a database access error occurs
0478:             */
0479:            public boolean nullPlusNonNullIsNull() {
0480:                return true;
0481:            }
0482:
0483:            /**
0484:             * Is the CONVERT function between SQL types supported?
0485:             *
0486:             * @return <code>true</code> if so; <code>false</code> otherwise
0487:             * @exception SQLException if a database access error occurs
0488:             */
0489:            public boolean supportsConvert() {
0490:                return false;
0491:            }
0492:
0493:            /**
0494:             * Is CONVERT between the given SQL types supported?
0495:             *
0496:             * @param fromType the type to convert from
0497:             * @param toType the type to convert to     
0498:             * @return <code>true</code> if so; <code>false</code> otherwise
0499:             * @exception SQLException if a database access error occurs
0500:             * @see Types
0501:             */
0502:            public boolean supportsConvert(int fromType, int toType) {
0503:                return false;
0504:            }
0505:
0506:            /**
0507:             * Are table correlation names supported?
0508:             *
0509:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0510:             *
0511:             * @return <code>true</code> if so; <code>false</code> otherwise
0512:             * @exception SQLException if a database access error occurs
0513:             */
0514:            public boolean supportsTableCorrelationNames() {
0515:                return false;
0516:            }
0517:
0518:            /**
0519:             * If table correlation names are supported, are they restricted
0520:             * to be different from the names of the tables?
0521:             *
0522:             * @return <code>true</code> if so; <code>false</code> otherwise 
0523:             * @exception SQLException if a database access error occurs
0524:             */
0525:            public boolean supportsDifferentTableCorrelationNames() {
0526:                return false;
0527:            }
0528:
0529:            /**
0530:             * Are expressions in "ORDER BY" lists supported?
0531:             *
0532:             * @return <code>true</code> if so; <code>false</code> otherwise
0533:             * @exception SQLException if a database access error occurs
0534:             */
0535:            public boolean supportsExpressionsInOrderBy() {
0536:                return false;
0537:            }
0538:
0539:            /**
0540:             * Supports statement pooling?
0541:             *
0542:             */
0543:            public boolean supportsStatementPooling() {
0544:                return false;
0545:            }
0546:
0547:            /**
0548:             * Can an "ORDER BY" clause use columns not in the SELECT statement?
0549:             *
0550:             * @return <code>true</code> if so; <code>false</code> otherwise
0551:             * @exception SQLException if a database access error occurs
0552:             */
0553:            public boolean supportsOrderByUnrelated() {
0554:                return false;
0555:            }
0556:
0557:            /**
0558:             * Is some form of "GROUP BY" clause supported?
0559:             *
0560:             * @return <code>true</code> if so; <code>false</code> otherwise
0561:             * @exception SQLException if a database access error occurs
0562:             */
0563:            public boolean supportsGroupBy() {
0564:                return false;
0565:            }
0566:
0567:            /**
0568:             * Can a "GROUP BY" clause use columns not in the SELECT?
0569:             *
0570:             * @return <code>true</code> if so; <code>false</code> otherwise
0571:             * @exception SQLException if a database access error occurs
0572:             */
0573:            public boolean supportsGroupByUnrelated() {
0574:                return false;
0575:            }
0576:
0577:            /**
0578:             * Can a "GROUP BY" clause add columns not in the SELECT
0579:             * provided it specifies all the columns in the SELECT?
0580:             *
0581:             * @return <code>true</code> if so; <code>false</code> otherwise
0582:             * @exception SQLException if a database access error occurs
0583:             */
0584:            public boolean supportsGroupByBeyondSelect() {
0585:                return false;
0586:            }
0587:
0588:            /**
0589:             * Is the escape character in "LIKE" clauses supported?
0590:             *
0591:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0592:             *
0593:             * @return <code>true</code> if so; <code>false</code> otherwise
0594:             * @exception SQLException if a database access error occurs
0595:             */
0596:            public boolean supportsLikeEscapeClause() {
0597:                return false;
0598:            }
0599:
0600:            /**
0601:             * Are multiple ResultSets from a single execute supported?
0602:             *
0603:             * @return <code>true</code> if so; <code>false</code> otherwise
0604:             * @exception SQLException if a database access error occurs
0605:             */
0606:            public boolean supportsMultipleResultSets() {
0607:                return false;
0608:            }
0609:
0610:            /**
0611:             * Can we have multiple transactions open at once (on different
0612:             * connections)?
0613:             *
0614:             * @return <code>true</code> if so; <code>false</code> otherwise
0615:             * @exception SQLException if a database access error occurs
0616:             */
0617:            public boolean supportsMultipleTransactions() {
0618:                return false;
0619:            }
0620:
0621:            /**
0622:             * Can columns be defined as non-nullable?
0623:             *
0624:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0625:             *
0626:             * @return <code>true</code> if so; <code>false</code> otherwise
0627:             * @exception SQLException if a database access error occurs
0628:             */
0629:            public boolean supportsNonNullableColumns() {
0630:                return false;
0631:            }
0632:
0633:            /**
0634:             * Is the ODBC Minimum SQL grammar supported?
0635:             *
0636:             * All JDBC Compliant<sup><font size=-2>TM</font></sup> drivers must return true.
0637:             *
0638:             * @return <code>true</code> if so; <code>false</code> otherwise
0639:             * @exception SQLException if a database access error occurs
0640:             */
0641:            public boolean supportsMinimumSQLGrammar() {
0642:                return false;
0643:            }
0644:
0645:            /**
0646:             * Is the ODBC Core SQL grammar supported?
0647:             *
0648:             * @return <code>true</code> if so; <code>false</code> otherwise
0649:             * @exception SQLException if a database access error occurs
0650:             */
0651:            public boolean supportsCoreSQLGrammar() {
0652:                return false;
0653:            }
0654:
0655:            /**
0656:             * Is the ODBC Extended SQL grammar supported?
0657:             *
0658:             * @return <code>true</code> if so; <code>false</code> otherwise
0659:             * @exception SQLException if a database access error occurs
0660:             */
0661:            public boolean supportsExtendedSQLGrammar() {
0662:                return false;
0663:            }
0664:
0665:            /**
0666:             * Is the ANSI92 entry level SQL grammar supported?
0667:             *
0668:             * All JDBC Compliant<sup><font size=-2>TM</font></sup> drivers must return true.
0669:             *
0670:             * @return <code>true</code> if so; <code>false</code> otherwise
0671:             * @exception SQLException if a database access error occurs
0672:             */
0673:            public boolean supportsANSI92EntryLevelSQL() {
0674:                return false;
0675:            }
0676:
0677:            /**
0678:             * Is the ANSI92 intermediate SQL grammar supported?
0679:             *
0680:             * @return <code>true</code> if so; <code>false</code> otherwise
0681:             * @exception SQLException if a database access error occurs
0682:             */
0683:            public boolean supportsANSI92IntermediateSQL() {
0684:                return false;
0685:            }
0686:
0687:            /**
0688:             * Is the ANSI92 full SQL grammar supported?
0689:             *
0690:             * @return <code>true</code> if so; <code>false</code> otherwise
0691:             * @exception SQLException if a database access error occurs
0692:             */
0693:            public boolean supportsANSI92FullSQL() {
0694:                return false;
0695:            }
0696:
0697:            /**
0698:             * Is the SQL Integrity Enhancement Facility supported?
0699:             *
0700:             * @return <code>true</code> if so; <code>false</code> otherwise
0701:             * @exception SQLException if a database access error occurs
0702:             */
0703:            public boolean supportsIntegrityEnhancementFacility() {
0704:                return false;
0705:            }
0706:
0707:            /**
0708:             * Is some form of outer join supported?
0709:             *
0710:             * @return <code>true</code> if so; <code>false</code> otherwise
0711:             * @exception SQLException if a database access error occurs
0712:             */
0713:            public boolean supportsOuterJoins() {
0714:                return false;
0715:            }
0716:
0717:            /**
0718:             * Are full nested outer joins supported?
0719:             *
0720:             * @return <code>true</code> if so; <code>false</code> otherwise
0721:             * @exception SQLException if a database access error occurs
0722:             */
0723:            public boolean supportsFullOuterJoins() {
0724:                return false;
0725:            }
0726:
0727:            /**
0728:             * Is there limited support for outer joins?  (This will be true
0729:             * if supportFullOuterJoins is true.)
0730:             *
0731:             * @return <code>true</code> if so; <code>false</code> otherwise
0732:             * @exception SQLException if a database access error occurs
0733:             */
0734:            public boolean supportsLimitedOuterJoins() {
0735:                return false;
0736:            }
0737:
0738:            /**
0739:             * What's the database vendor's preferred term for "schema"?
0740:             *
0741:             * @return the vendor term
0742:             * @exception SQLException if a database access error occurs
0743:             */
0744:            public String getSchemaTerm() throws SQLException {
0745:                throw new SQLException("tinySQL does not support schema term.");
0746:            }
0747:
0748:            /**
0749:             * What's the database vendor's preferred term for "procedure"?
0750:             *
0751:             * @return the vendor term
0752:             * @exception SQLException if a database access error occurs
0753:             */
0754:            public String getProcedureTerm() throws SQLException {
0755:                throw new SQLException("tinySQL does not support procedure.");
0756:            }
0757:
0758:            /**
0759:             * What's the database vendor's preferred term for "catalog"?
0760:             *
0761:             * @return the vendor term
0762:             * @exception SQLException if a database access error occurs
0763:             */
0764:            public String getCatalogTerm() throws SQLException {
0765:                throw new SQLException("tinySQL does not support catalog.");
0766:            }
0767:
0768:            /**
0769:             * Does a catalog appear at the start of a qualified table name?
0770:             * (Otherwise it appears at the end)
0771:             *
0772:             * @return true if it appears at the start 
0773:             * @exception SQLException if a database access error occurs
0774:             */
0775:            public boolean isCatalogAtStart() {
0776:                return false;
0777:            }
0778:
0779:            /**
0780:             * What's the separator between catalog and table name?
0781:             *
0782:             * @return the separator string
0783:             * @exception SQLException if a database access error occurs
0784:             */
0785:            public String getCatalogSeparator() throws SQLException {
0786:                throw new SQLException("tinySQL does not catalog.");
0787:            }
0788:
0789:            /**
0790:             * Can a schema name be used in a data manipulation statement?
0791:             *
0792:             * @return <code>true</code> if so; <code>false</code> otherwise
0793:             * @exception SQLException if a database access error occurs
0794:             */
0795:            public boolean supportsSchemasInDataManipulation() {
0796:                return false;
0797:            }
0798:
0799:            /**
0800:             * Can a schema name be used in a procedure call statement?
0801:             *
0802:             * @return <code>true</code> if so; <code>false</code> otherwise
0803:             * @exception SQLException if a database access error occurs
0804:             */
0805:            public boolean supportsSchemasInProcedureCalls() {
0806:                return false;
0807:            }
0808:
0809:            /**
0810:             * Can a schema name be used in a table definition statement?
0811:             *
0812:             * @return <code>true</code> if so; <code>false</code> otherwise
0813:             * @exception SQLException if a database access error occurs
0814:             */
0815:            public boolean supportsSchemasInTableDefinitions() {
0816:                return false;
0817:            }
0818:
0819:            /**
0820:             * Can a schema name be used in an index definition statement?
0821:             *
0822:             * @return <code>true</code> if so; <code>false</code> otherwise
0823:             * @exception SQLException if a database access error occurs
0824:             */
0825:            public boolean supportsSchemasInIndexDefinitions() {
0826:                return false;
0827:            }
0828:
0829:            /**
0830:             * Can a schema name be used in a privilege definition statement?
0831:             *
0832:             * @return <code>true</code> if so; <code>false</code> otherwise
0833:             * @exception SQLException if a database access error occurs
0834:             */
0835:            public boolean supportsSchemasInPrivilegeDefinitions() {
0836:                return false;
0837:            }
0838:
0839:            /**
0840:             * Can a catalog name be used in a data manipulation statement?
0841:             *
0842:             * @return <code>true</code> if so; <code>false</code> otherwise
0843:             * @exception SQLException if a database access error occurs
0844:             */
0845:            public boolean supportsCatalogsInDataManipulation() {
0846:                return false;
0847:            }
0848:
0849:            /**
0850:             * Can a catalog name be used in a procedure call statement?
0851:             *
0852:             * @return <code>true</code> if so; <code>false</code> otherwise
0853:             * @exception SQLException if a database access error occurs
0854:             */
0855:            public boolean supportsCatalogsInProcedureCalls() {
0856:                return false;
0857:            }
0858:
0859:            /**
0860:             * Can a catalog name be used in a table definition statement?
0861:             *
0862:             * @return <code>true</code> if so; <code>false</code> otherwise
0863:             * @exception SQLException if a database access error occurs
0864:             */
0865:            public boolean supportsCatalogsInTableDefinitions() {
0866:                return false;
0867:            }
0868:
0869:            /**
0870:             * Can a catalog name be used in an index definition statement?
0871:             *
0872:             * @return <code>true</code> if so; <code>false</code> otherwise
0873:             * @exception SQLException if a database access error occurs
0874:             */
0875:            public boolean supportsCatalogsInIndexDefinitions() {
0876:                return false;
0877:            }
0878:
0879:            /**
0880:             * Can a catalog name be used in a privilege definition statement?
0881:             *
0882:             * @return <code>true</code> if so; <code>false</code> otherwise
0883:             * @exception SQLException if a database access error occurs
0884:             */
0885:            public boolean supportsCatalogsInPrivilegeDefinitions() {
0886:                return false;
0887:            }
0888:
0889:            /**
0890:             * Is positioned DELETE supported?
0891:             *
0892:             * @return <code>true</code> if so; <code>false</code> otherwise
0893:             * @exception SQLException if a database access error occurs
0894:             */
0895:            public boolean supportsPositionedDelete() {
0896:                return false;
0897:            }
0898:
0899:            /**
0900:             * Is positioned UPDATE supported?
0901:             *
0902:             * @return <code>true</code> if so; <code>false</code> otherwise
0903:             * @exception SQLException if a database access error occurs
0904:             */
0905:            public boolean supportsPositionedUpdate() {
0906:                return false;
0907:            }
0908:
0909:            /**
0910:             * Is SELECT for UPDATE supported?
0911:             *
0912:             * @return <code>true</code> if so; <code>false</code> otherwise
0913:             * @exception SQLException if a database access error occurs
0914:             */
0915:            public boolean supportsSelectForUpdate() {
0916:                return false;
0917:            }
0918:
0919:            /**
0920:             * Are stored procedure calls using the stored procedure escape
0921:             * syntax supported?
0922:             *
0923:             * @return <code>true</code> if so; <code>false</code> otherwise 
0924:             * @exception SQLException if a database access error occurs
0925:             */
0926:            public boolean supportsStoredProcedures() {
0927:                return false;
0928:            }
0929:
0930:            /**
0931:             * Are subqueries in comparison expressions supported?
0932:             *
0933:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0934:             *
0935:             * @return <code>true</code> if so; <code>false</code> otherwise
0936:             * @exception SQLException if a database access error occurs
0937:             */
0938:            public boolean supportsSubqueriesInComparisons() {
0939:                return false;
0940:            }
0941:
0942:            /**
0943:             * Are subqueries in 'exists' expressions supported?
0944:             *
0945:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0946:             *
0947:             * @return <code>true</code> if so; <code>false</code> otherwise
0948:             * @exception SQLException if a database access error occurs
0949:             */
0950:            public boolean supportsSubqueriesInExists() {
0951:                return false;
0952:            }
0953:
0954:            /**
0955:             * Are subqueries in 'in' statements supported?
0956:             *
0957:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0958:             *
0959:             * @return <code>true</code> if so; <code>false</code> otherwise
0960:             * @exception SQLException if a database access error occurs
0961:             */
0962:            public boolean supportsSubqueriesInIns() {
0963:                return false;
0964:            }
0965:
0966:            /**
0967:             * Are subqueries in quantified expressions supported?
0968:             *
0969:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0970:             *
0971:             * @return <code>true</code> if so; <code>false</code> otherwise
0972:             * @exception SQLException if a database access error occurs
0973:             */
0974:            public boolean supportsSubqueriesInQuantifieds() {
0975:                return false;
0976:            }
0977:
0978:            /**
0979:             * Are correlated subqueries supported?
0980:             *
0981:             * A JDBC Compliant<sup><font size=-2>TM</font></sup> driver always returns true.
0982:             *
0983:             * @return <code>true</code> if so; <code>false</code> otherwise
0984:             * @exception SQLException if a database access error occurs
0985:             */
0986:            public boolean supportsCorrelatedSubqueries() {
0987:                return false;
0988:            }
0989:
0990:            /**
0991:             * Is SQL UNION supported?
0992:             *
0993:             * @return <code>true</code> if so; <code>false</code> otherwise
0994:             * @exception SQLException if a database access error occurs
0995:             */
0996:            public boolean supportsUnion() {
0997:                return false;
0998:            }
0999:
1000:            /**
1001:             * Is SQL UNION ALL supported?
1002:             *
1003:             * @return <code>true</code> if so; <code>false</code> otherwise
1004:             * @exception SQLException if a database access error occurs
1005:             */
1006:            public boolean supportsUnionAll() {
1007:                return false;
1008:            }
1009:
1010:            /**
1011:             * Can cursors remain open across commits? 
1012:             * 
1013:             * @return <code>true</code> if cursors always remain open;
1014:             *       <code>false</code> if they might not remain open
1015:             * @exception SQLException if a database access error occurs
1016:             */
1017:            public boolean supportsOpenCursorsAcrossCommit() {
1018:                return false;
1019:            }
1020:
1021:            /**
1022:             * Can cursors remain open across rollbacks?
1023:             * 
1024:             * @return <code>true</code> if cursors always remain open;
1025:             *       <code>false</code> if they might not remain open
1026:             * @exception SQLException if a database access error occurs
1027:             */
1028:            public boolean supportsOpenCursorsAcrossRollback() {
1029:                return false;
1030:            }
1031:
1032:            /**
1033:             * Can statements remain open across commits?
1034:             * 
1035:             * @return <code>true</code> if statements always remain open;
1036:             *       <code>false</code> if they might not remain open
1037:             * @exception SQLException if a database access error occurs
1038:             */
1039:            public boolean supportsOpenStatementsAcrossCommit() {
1040:                return false;
1041:            }
1042:
1043:            /**
1044:             * Can statements remain open across rollbacks?
1045:             * 
1046:             * @return <code>true</code> if statements always remain open;
1047:             *       <code>false</code> if they might not remain open
1048:             * @exception SQLException if a database access error occurs
1049:             */
1050:            public boolean supportsOpenStatementsAcrossRollback() {
1051:                return false;
1052:            }
1053:
1054:            //----------------------------------------------------------------------
1055:            // The following group of methods exposes various limitations 
1056:            // based on the target database with the current driver.
1057:            // Unless otherwise specified, a result of zero means there is no
1058:            // limit, or the limit is not known.
1059:
1060:            /**
1061:             * How many hex characters can you have in an inline binary literal?
1062:             *
1063:             * @return max binary literal length in hex characters;
1064:             *      a result of zero means that there is no limit or the limit is not known
1065:             * @exception SQLException if a database access error occurs
1066:             */
1067:            public int getMaxBinaryLiteralLength() {
1068:                return 0;
1069:            }
1070:
1071:            /**
1072:             * What's the max length for a character literal?
1073:             *
1074:             * @return max literal length;
1075:             *      a result of zero means that there is no limit or the limit is not known
1076:             * @exception SQLException if a database access error occurs
1077:             */
1078:            public int getMaxCharLiteralLength() {
1079:                return 0;
1080:            }
1081:
1082:            /**
1083:             * What's the limit on column name length?
1084:             *
1085:             * @return max column name length;
1086:             *      a result of zero means that there is no limit or the limit is not known
1087:             * @exception SQLException if a database access error occurs
1088:             */
1089:            public int getMaxColumnNameLength() {
1090:                return 10;
1091:            }
1092:
1093:            /**
1094:             * What's the maximum number of columns in a "GROUP BY" clause?
1095:             *
1096:             * @return max number of columns;
1097:             *      a result of zero means that there is no limit or the limit is not known
1098:             * @exception SQLException if a database access error occurs
1099:             */
1100:            public int getMaxColumnsInGroupBy() {
1101:                return 0;
1102:            }
1103:
1104:            /**
1105:             * What's the maximum number of columns allowed in an index?
1106:             *
1107:             * @return max number of columns;
1108:             *      a result of zero means that there is no limit or the limit is not known
1109:             * @exception SQLException if a database access error occurs
1110:             */
1111:            public int getMaxColumnsInIndex() {
1112:                return 0;
1113:            }
1114:
1115:            /**
1116:             * What's the maximum number of columns in an "ORDER BY" clause?
1117:             *
1118:             * @return max number of columns;
1119:             *      a result of zero means that there is no limit or the limit is not known
1120:             * @exception SQLException if a database access error occurs
1121:             */
1122:            public int getMaxColumnsInOrderBy() {
1123:                return 0;
1124:            }
1125:
1126:            /**
1127:             * What's the maximum number of columns in a "SELECT" list?
1128:             *
1129:             * @return max number of columns;
1130:             *      a result of zero means that there is no limit or the limit is not known
1131:             * @exception SQLException if a database access error occurs
1132:             */
1133:            public int getMaxColumnsInSelect() {
1134:                return 10000; // !!!
1135:            }
1136:
1137:            /**
1138:             * What's the maximum number of columns in a table?
1139:             *
1140:             * @return max number of columns;
1141:             *      a result of zero means that there is no limit or the limit is not known
1142:             * @exception SQLException if a database access error occurs
1143:             */
1144:            public int getMaxColumnsInTable() {
1145:                return 10000; // !!!
1146:            }
1147:
1148:            /**
1149:             * How many active connections can we have at a time to this database?
1150:             *
1151:             * @return max number of active connections;
1152:             *      a result of zero means that there is no limit or the limit is not known
1153:             * @exception SQLException if a database access error occurs
1154:             */
1155:            public int getMaxConnections() {
1156:                return 1; // !!!
1157:            }
1158:
1159:            /**
1160:             * What's the maximum cursor name length?
1161:             *
1162:             * @return max cursor name length in bytes;
1163:             *      a result of zero means that there is no limit or the limit is not known
1164:             * @exception SQLException if a database access error occurs
1165:             */
1166:            public int getMaxCursorNameLength() {
1167:                return 0;
1168:            }
1169:
1170:            /**
1171:             * What's the maximum length of an index (in bytes)?  
1172:             *
1173:             * @return max index length in bytes;
1174:             *      a result of zero means that there is no limit or the limit is not known
1175:             * @exception SQLException if a database access error occurs
1176:             */
1177:            public int getMaxIndexLength() {
1178:                return 0;
1179:            }
1180:
1181:            /**
1182:             * What's the maximum length allowed for a schema name?
1183:             *
1184:             * @return max name length in bytes;
1185:             *      a result of zero means that there is no limit or the limit is not known
1186:             * @exception SQLException if a database access error occurs
1187:             */
1188:            public int getMaxSchemaNameLength() {
1189:                return 0;
1190:            }
1191:
1192:            /**
1193:             * What's the maximum length of a procedure name?
1194:             *
1195:             * @return max name length in bytes; 
1196:             *      a result of zero means that there is no limit or the limit is not known
1197:             * @exception SQLException if a database access error occurs
1198:             */
1199:            public int getMaxProcedureNameLength() {
1200:                return 0;
1201:            }
1202:
1203:            /**
1204:             * What's the maximum length of a catalog name?
1205:             *
1206:             * @return max name length in bytes;
1207:             *      a result of zero means that there is no limit or the limit is not known
1208:             * @exception SQLException if a database access error occurs
1209:             */
1210:            public int getMaxCatalogNameLength() {
1211:                return 0;
1212:            }
1213:
1214:            /**
1215:             * What's the maximum length of a single row?
1216:             *
1217:             * @return max row size in bytes;
1218:             *      a result of zero means that there is no limit or the limit is not known
1219:             * @exception SQLException if a database access error occurs
1220:             */
1221:            public int getMaxRowSize() {
1222:                return 0;
1223:                // The maxRowSize() depends on each dBase file, so it can´t be told here generally
1224:                // return connection.getTinySqlHandle().getTableHandle("xy").getRecordLength();
1225:            }
1226:
1227:            /**
1228:             * Did getMaxRowSize() include LONGVARCHAR and LONGVARBINARY
1229:             * blobs?
1230:             *
1231:             * @return <code>true</code> if so; <code>false</code> otherwise 
1232:             * @exception SQLException if a database access error occurs
1233:             */
1234:            public boolean doesMaxRowSizeIncludeBlobs() {
1235:                return false;
1236:            }
1237:
1238:            /**
1239:             * What's the maximum length of a SQL statement?
1240:             *
1241:             * @return max length in bytes;
1242:             *      a result of zero means that there is no limit or the limit is not known
1243:             * @exception SQLException if a database access error occurs
1244:             */
1245:            public int getMaxStatementLength() {
1246:                return 0;
1247:            }
1248:
1249:            /**
1250:             * How many active statements can we have open at one time to this
1251:             * database?
1252:             *
1253:             * @return the maximum number of statements that can be open at one time;
1254:             *      a result of zero means that there is no limit or the limit is not known
1255:             * @exception SQLException if a database access error occurs
1256:             */
1257:            public int getMaxStatements() {
1258:                return 10; // !!!
1259:            }
1260:
1261:            /**
1262:             * What's the maximum length of a table name?
1263:             *
1264:             * @return max name length in bytes;
1265:             *      a result of zero means that there is no limit or the limit is not known
1266:             * @exception SQLException if a database access error occurs
1267:             */
1268:            public int getMaxTableNameLength() {
1269:                return 32; // !!! filesystem name
1270:            }
1271:
1272:            /**
1273:             * What's the maximum number of tables in a SELECT statement?
1274:             *
1275:             * @return the maximum number of tables allowed in a SELECT statement;
1276:             *      a result of zero means that there is no limit or the limit is not known
1277:             * @exception SQLException if a database access error occurs
1278:             */
1279:            public int getMaxTablesInSelect() {
1280:                return 1; // !!!
1281:            }
1282:
1283:            /**
1284:             * What's the maximum length of a user name?
1285:             *
1286:             * @return max user name length  in bytes;
1287:             *      a result of zero means that there is no limit or the limit is not known
1288:             * @exception SQLException if a database access error occurs
1289:             */
1290:            public int getMaxUserNameLength() {
1291:                return 0;
1292:            }
1293:
1294:            //----------------------------------------------------------------------
1295:
1296:            /**
1297:             * What's the database's default transaction isolation level?  The
1298:             * values are defined in <code>java.sql.Connection</code>.
1299:             *
1300:             * @return the default isolation level 
1301:             * @exception SQLException if a database access error occurs
1302:             * @see Connection
1303:             */
1304:            public int getDefaultTransactionIsolation() throws SQLException {
1305:                throw new SQLException(
1306:                        "tinySQL does not support transaction isolation.");
1307:            }
1308:
1309:            /**
1310:             * Are transactions supported? If not, invoking the method
1311:             * <code>commit</code> is a noop and the
1312:             * isolation level is TRANSACTION_NONE.
1313:             *
1314:             * @return <code>true</code> if transactions are supported; <code>false</code> otherwise 
1315:             * @exception SQLException if a database access error occurs
1316:             */
1317:            public boolean supportsTransactions() {
1318:                return false;
1319:            }
1320:
1321:            /**
1322:             * Does this database support the given transaction isolation level?
1323:             *
1324:             * @param level the values are defined in <code>java.sql.Connection</code>
1325:             * @return <code>true</code> if so; <code>false</code> otherwise 
1326:             * @exception SQLException if a database access error occurs
1327:             * @see Connection
1328:             */
1329:            public boolean supportsTransactionIsolationLevel(int level) {
1330:                return false;
1331:            }
1332:
1333:            /**
1334:             * Are both data definition and data manipulation statements
1335:             * within a transaction supported?
1336:             *
1337:             * @return <code>true</code> if so; <code>false</code> otherwise 
1338:             * @exception SQLException if a database access error occurs
1339:             */
1340:            public boolean supportsDataDefinitionAndDataManipulationTransactions() {
1341:                return false;
1342:            }
1343:
1344:            /**
1345:             * Are only data manipulation statements within a transaction
1346:             * supported?
1347:             *
1348:             * @return <code>true</code> if so; <code>false</code> otherwise
1349:             * @exception SQLException if a database access error occurs
1350:             */
1351:            public boolean supportsDataManipulationTransactionsOnly() {
1352:                return false;
1353:            }
1354:
1355:            /**
1356:             * Does a data definition statement within a transaction force the
1357:             * transaction to commit?
1358:             *
1359:             * @return <code>true</code> if so; <code>false</code> otherwise 
1360:             * @exception SQLException if a database access error occurs
1361:             */
1362:            public boolean dataDefinitionCausesTransactionCommit() {
1363:                return false;
1364:            }
1365:
1366:            /**
1367:             * Is a data definition statement within a transaction ignored?
1368:             *
1369:             * @return <code>true</code> if so; <code>false</code> otherwise 
1370:             * @exception SQLException if a database access error occurs
1371:             */
1372:            public boolean dataDefinitionIgnoredInTransactions()
1373:                    throws SQLException {
1374:                throw new SQLException("tinySQL does not support transactions.");
1375:            }
1376:
1377:            /**
1378:             * Gets a description of the stored procedures available in a
1379:             * catalog.
1380:             *
1381:             * <P>Only procedure descriptions matching the schema and
1382:             * procedure name criteria are returned.  They are ordered by
1383:             * PROCEDURE_SCHEM, and PROCEDURE_NAME.
1384:             *
1385:             * <P>Each procedure description has the the following columns:
1386:             *  <OL>
1387:             *  <LI><B>PROCEDURE_CAT</B> String => procedure catalog (may be null)
1388:             *  <LI><B>PROCEDURE_SCHEM</B> String => procedure schema (may be null)
1389:             *  <LI><B>PROCEDURE_NAME</B> String => procedure name
1390:             *  <LI> reserved for future use
1391:             *  <LI> reserved for future use
1392:             *  <LI> reserved for future use
1393:             *  <LI><B>REMARKS</B> String => explanatory comment on the procedure
1394:             *  <LI><B>PROCEDURE_TYPE</B> short => kind of procedure:
1395:             *      <UL>
1396:             *      <LI> procedureResultUnknown - May return a result
1397:             *      <LI> procedureNoResult - Does not return a result
1398:             *      <LI> procedureReturnsResult - Returns a result
1399:             *      </UL>
1400:             *  </OL>
1401:             *
1402:             * @param catalog a catalog name; "" retrieves those without a
1403:             * catalog; null means drop catalog name from the selection criteria
1404:             * @param schemaPattern a schema name pattern; "" retrieves those
1405:             * without a schema
1406:             * @param procedureNamePattern a procedure name pattern 
1407:             * @return ResultSet - each row is a procedure description 
1408:             * @exception SQLException if a database access error occurs
1409:             * @see #getSearchStringEscape 
1410:             */
1411:            public ResultSet getProcedures(String catalog,
1412:                    String schemaPattern, String procedureNamePattern) {
1413:                return null;
1414:            }
1415:
1416:            /**
1417:             * A possible value for column <code>PROCEDURE_TYPE</code> in the
1418:             * <code>ResultSet</code> object returned by the method
1419:             * <code>getProcedures</code>.
1420:             * <p> Indicates that it is not known whether the procedure returns
1421:             * a result.
1422:             */
1423:            int procedureResultUnknown = 0;
1424:
1425:            /**
1426:             * A possible value for column <code>PROCEDURE_TYPE</code> in the
1427:             * <code>ResultSet</code> object returned by the method
1428:             * <code>getProcedures</code>.
1429:             * <p> Indicates that the procedure does not return
1430:             * a result.
1431:             */
1432:            int procedureNoResult = 1;
1433:
1434:            /**
1435:             * A possible value for column <code>PROCEDURE_TYPE</code> in the
1436:             * <code>ResultSet</code> object returned by the method
1437:             * <code>getProcedures</code>.
1438:             * <p> Indicates that the procedure returns
1439:             * a result.
1440:             */
1441:            int procedureReturnsResult = 2;
1442:
1443:            /**
1444:             * Gets a description of a catalog's stored procedure parameters
1445:             * and result columns.
1446:             *
1447:             * <P>Only descriptions matching the schema, procedure and
1448:             * parameter name criteria are returned.  They are ordered by
1449:             * PROCEDURE_SCHEM and PROCEDURE_NAME. Within this, the return value,
1450:             * if any, is first. Next are the parameter descriptions in call
1451:             * order. The column descriptions follow in column number order.
1452:             *
1453:             * <P>Each row in the ResultSet is a parameter description or
1454:             * column description with the following fields:
1455:             *  <OL>
1456:             *  <LI><B>PROCEDURE_CAT</B> String => procedure catalog (may be null)
1457:             *  <LI><B>PROCEDURE_SCHEM</B> String => procedure schema (may be null)
1458:             *  <LI><B>PROCEDURE_NAME</B> String => procedure name
1459:             *  <LI><B>COLUMN_NAME</B> String => column/parameter name 
1460:             *  <LI><B>COLUMN_TYPE</B> Short => kind of column/parameter:
1461:             *      <UL>
1462:             *      <LI> procedureColumnUnknown - nobody knows
1463:             *      <LI> procedureColumnIn - IN parameter
1464:             *      <LI> procedureColumnInOut - INOUT parameter
1465:             *      <LI> procedureColumnOut - OUT parameter
1466:             *      <LI> procedureColumnReturn - procedure return value
1467:             *      <LI> procedureColumnResult - result column in ResultSet
1468:             *      </UL>
1469:             *  <LI><B>DATA_TYPE</B> short => SQL type from java.sql.Types
1470:             *  <LI><B>TYPE_NAME</B> String => SQL type name, for a UDT type the
1471:             *  type name is fully qualified
1472:             *  <LI><B>PRECISION</B> int => precision
1473:             *  <LI><B>LENGTH</B> int => length in bytes of data
1474:             *  <LI><B>SCALE</B> short => scale
1475:             *  <LI><B>RADIX</B> short => radix
1476:             *  <LI><B>NULLABLE</B> short => can it contain NULL?
1477:             *      <UL>
1478:             *      <LI> procedureNoNulls - does not allow NULL values
1479:             *      <LI> procedureNullable - allows NULL values
1480:             *      <LI> procedureNullableUnknown - nullability unknown
1481:             *      </UL>
1482:             *  <LI><B>REMARKS</B> String => comment describing parameter/column
1483:             *  </OL>
1484:             *
1485:             * <P><B>Note:</B> Some databases may not return the column
1486:             * descriptions for a procedure. Additional columns beyond
1487:             * REMARKS can be defined by the database.
1488:             *
1489:             * @param catalog a catalog name; "" retrieves those without a
1490:             * catalog; null means drop catalog name from the selection criteria
1491:             * @param schemaPattern a schema name pattern; "" retrieves those
1492:             * without a schema 
1493:             * @param procedureNamePattern a procedure name pattern 
1494:             * @param columnNamePattern a column name pattern 
1495:             * @return ResultSet - each row describes a stored procedure parameter or 
1496:             *      column
1497:             * @exception SQLException if a database access error occurs
1498:             * @see #getSearchStringEscape 
1499:             */
1500:            public ResultSet getProcedureColumns(String catalog,
1501:                    String schemaPattern, String procedureNamePattern,
1502:                    String columnNamePattern) {
1503:                return null;
1504:            }
1505:
1506:            /**
1507:             * Indicates that type of the column is unknown.
1508:             * A possible value for the column
1509:             * <code>COLUMN_TYPE</code>
1510:             * in the <code>ResultSet</code> 
1511:             * returned by the method <code>getProcedureColumns</code>.
1512:             */
1513:            int procedureColumnUnknown = 0;
1514:
1515:            /**
1516:             * Indicates that the column stores IN parameters.
1517:             * A possible value for the column
1518:             * <code>COLUMN_TYPE</code>
1519:             * in the <code>ResultSet</code> 
1520:             * returned by the method <code>getProcedureColumns</code>.
1521:             */
1522:            int procedureColumnIn = 1;
1523:
1524:            /**
1525:             * Indicates that the column stores INOUT parameters.
1526:             * A possible value for the column
1527:             * <code>COLUMN_TYPE</code>
1528:             * in the <code>ResultSet</code> 
1529:             * returned by the method <code>getProcedureColumns</code>.
1530:             */
1531:            int procedureColumnInOut = 2;
1532:
1533:            /**
1534:             * Indicates that the column stores OUT parameters.
1535:             * A possible value for the column
1536:             * <code>COLUMN_TYPE</code>
1537:             * in the <code>ResultSet</code> 
1538:             * returned by the method <code>getProcedureColumns</code>.
1539:             */
1540:            int procedureColumnOut = 4;
1541:            /**
1542:             * Indicates that the column stores return values.
1543:             * A possible value for the column
1544:             * <code>COLUMN_TYPE</code>
1545:             * in the <code>ResultSet</code> 
1546:             * returned by the method <code>getProcedureColumns</code>.
1547:             */
1548:            int procedureColumnReturn = 5;
1549:
1550:            /**
1551:             * Indicates that the column stores results.
1552:             * A possible value for the column
1553:             * <code>COLUMN_TYPE</code>
1554:             * in the <code>ResultSet</code> 
1555:             * returned by the method <code>getProcedureColumns</code>.
1556:             */
1557:            int procedureColumnResult = 3;
1558:
1559:            /**
1560:             * Indicates that <code>NULL</code> values are not allowed.
1561:             * A possible value for the column
1562:             * <code>NULLABLE</code>
1563:             * in the <code>ResultSet</code> 
1564:             * returned by the method <code>getProcedureColumns</code>.
1565:             */
1566:            int procedureNoNulls = 0;
1567:
1568:            /**
1569:             * Indicates that <code>NULL</code> values are allowed.
1570:             * A possible value for the column
1571:             * <code>NULLABLE</code>
1572:             * in the <code>ResultSet</code> 
1573:             * returned by the method <code>getProcedureColumns</code>.
1574:             */
1575:            int procedureNullable = 1;
1576:
1577:            /**
1578:             * Indicates that whether <code>NULL</code> values are allowed
1579:             * is unknown.
1580:             * A possible value for the column
1581:             * <code>NULLABLE</code>
1582:             * in the <code>ResultSet</code> 
1583:             * returned by the method <code>getProcedureColumns</code>.
1584:             */
1585:            int procedureNullableUnknown = 2;
1586:
1587:            /**
1588:             * Gets a description of tables available in a catalog.
1589:             *
1590:             * <P>Only table descriptions matching the catalog, schema, table
1591:             * name and type criteria are returned.  They are ordered by
1592:             * TABLE_TYPE, TABLE_SCHEM and TABLE_NAME.
1593:             *
1594:             * <P>Each table description has the following columns:
1595:             *  <OL>
1596:             *  <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1597:             *  <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1598:             *  <LI><B>TABLE_NAME</B> String => table name
1599:             *  <LI><B>TABLE_TYPE</B> String => table type.  Typical types are "TABLE",
1600:             *      "VIEW", "SYSTEM TABLE", "GLOBAL TEMPORARY", 
1601:             *      "LOCAL TEMPORARY", "ALIAS", "SYNONYM".
1602:             *  <LI><B>REMARKS</B> String => explanatory comment on the table
1603:             *  </OL>
1604:             *
1605:             * <P><B>Note:</B> Some databases may not return information for
1606:             * all tables.
1607:             *
1608:             * @param catalog a catalog name; "" retrieves those without a
1609:             * catalog; null means drop catalog name from the selection criteria
1610:             * @param schemaPattern a schema name pattern; "" retrieves those
1611:             * without a schema
1612:             * @param tableNamePattern a table name pattern 
1613:             * @param types a list of table types to include; null returns all types 
1614:             * @return ResultSet - each row is a table description
1615:             * @exception SQLException if a database access error occurs
1616:             * @see #getSearchStringEscape 
1617:             */
1618:            public ResultSet getTables(String catalog, String schemaPattern,
1619:                    String tableNamePattern, String types[]) {
1620:                return null; // !!!
1621:            }
1622:
1623:            /**
1624:             * Gets the schema names available in this database.  The results
1625:             * are ordered by schema name.
1626:             *
1627:             * <P>The schema column is:
1628:             *  <OL>
1629:             *  <LI><B>TABLE_SCHEM</B> String => schema name
1630:             *  </OL>
1631:             *
1632:             * @return ResultSet - each row has a single String column that is a
1633:             * schema name 
1634:             * @exception SQLException if a database access error occurs
1635:             */
1636:            public ResultSet getSchemas() throws SQLException {
1637:                throw new SQLException("tinySQL does not support schemas.");
1638:            }
1639:
1640:            /**
1641:             * Gets the catalog names available in this database.  The results
1642:             * are ordered by catalog name.
1643:             *
1644:             * <P>The catalog column is:
1645:             *  <OL>
1646:             *  <LI><B>TABLE_CAT</B> String => catalog name
1647:             *  </OL>
1648:             *
1649:             * @return ResultSet - each row has a single String column that is a
1650:             * catalog name 
1651:             * @exception SQLException if a database access error occurs
1652:             */
1653:            public ResultSet getCatalogs() throws SQLException {
1654:                throw new SQLException("tinySQL does not support catalogues.");
1655:            }
1656:
1657:            /**
1658:             * Gets the table types available in this database.  The results
1659:             * are ordered by table type.
1660:             *
1661:             * <P>The table type is:
1662:             *  <OL>
1663:             *  <LI><B>TABLE_TYPE</B> String => table type.  Typical types are "TABLE",
1664:             *      "VIEW", "SYSTEM TABLE", "GLOBAL TEMPORARY", 
1665:             *      "LOCAL TEMPORARY", "ALIAS", "SYNONYM".
1666:             *  </OL>
1667:             *
1668:             * @return ResultSet - each row has a single String column that is a
1669:             * table type 
1670:             * @exception SQLException if a database access error occurs
1671:             */
1672:            public ResultSet getTableTypes() {
1673:                return null; // !!!
1674:            }
1675:
1676:            /**
1677:             * Gets a description of table columns available in 
1678:             * the specified catalog.
1679:             *
1680:             * <P>Only column descriptions matching the catalog, schema, table
1681:             * and column name criteria are returned.  They are ordered by
1682:             * TABLE_SCHEM, TABLE_NAME and ORDINAL_POSITION.
1683:             *
1684:             * <P>Each column description has the following columns:
1685:             *  <OL>
1686:             *  <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1687:             *  <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1688:             *  <LI><B>TABLE_NAME</B> String => table name
1689:             *  <LI><B>COLUMN_NAME</B> String => column name
1690:             *  <LI><B>DATA_TYPE</B> short => SQL type from java.sql.Types
1691:             *  <LI><B>TYPE_NAME</B> String => Data source dependent type name,
1692:             *  for a UDT the type name is fully qualified
1693:             *  <LI><B>COLUMN_SIZE</B> int => column size.  For char or date
1694:             *      types this is the maximum number of characters, for numeric or
1695:             *      decimal types this is precision.
1696:             *  <LI><B>BUFFER_LENGTH</B> is not used.
1697:             *  <LI><B>DECIMAL_DIGITS</B> int => the number of fractional digits
1698:             *  <LI><B>NUM_PREC_RADIX</B> int => Radix (typically either 10 or 2)
1699:             *  <LI><B>NULLABLE</B> int => is NULL allowed?
1700:             *      <UL>
1701:             *      <LI> columnNoNulls - might not allow NULL values
1702:             *      <LI> columnNullable - definitely allows NULL values
1703:             *      <LI> columnNullableUnknown - nullability unknown
1704:             *      </UL>
1705:             *  <LI><B>REMARKS</B> String => comment describing column (may be null)
1706:             *  <LI><B>COLUMN_DEF</B> String => default value (may be null)
1707:             *  <LI><B>SQL_DATA_TYPE</B> int => unused
1708:             *  <LI><B>SQL_DATETIME_SUB</B> int => unused
1709:             *  <LI><B>CHAR_OCTET_LENGTH</B> int => for char types the 
1710:             *       maximum number of bytes in the column
1711:             *  <LI><B>ORDINAL_POSITION</B> int => index of column in table 
1712:             *      (starting at 1)
1713:             *  <LI><B>IS_NULLABLE</B> String => "NO" means column definitely 
1714:             *      does not allow NULL values; "YES" means the column might 
1715:             *      allow NULL values.  An empty string means nobody knows.
1716:             *  </OL>
1717:             *
1718:             * @param catalog a catalog name; "" retrieves those without a
1719:             * catalog; null means drop catalog name from the selection criteria
1720:             * @param schemaPattern a schema name pattern; "" retrieves those
1721:             * without a schema
1722:             * @param tableNamePattern a table name pattern 
1723:             * @param columnNamePattern a column name pattern 
1724:             * @return ResultSet - each row is a column description
1725:             * @exception SQLException if a database access error occurs
1726:             * @see #getSearchStringEscape 
1727:             */
1728:            public ResultSet getColumns(String catalog, String schemaPattern,
1729:                    String tableNamePattern, String columnNamePattern) {
1730:                Utils.log("tinySQL does not support getColumns().");
1731:                return null;
1732:            }
1733:
1734:            /**
1735:             * Indicates that the column might not allow NULL values.
1736:             * A possible value for the column
1737:             * <code>NULLABLE</code>
1738:             * in the <code>ResultSet</code> returned by the method
1739:             * <code>getColumns</code>.
1740:             */
1741:            int columnNoNulls = 0;
1742:
1743:            /**
1744:             * Indicates that the column definitely allows <code>NULL</code> values.
1745:             * A possible value for the column
1746:             * <code>NULLABLE</code>
1747:             * in the <code>ResultSet</code> returned by the method
1748:             * <code>getColumns</code>.
1749:             */
1750:            int columnNullable = 1;
1751:
1752:            /**
1753:             * Indicates that the nullability of columns is unknown.
1754:             * A possible value for the column
1755:             * <code>NULLABLE</code>
1756:             * in the <code>ResultSet</code> returned by the method
1757:             * <code>getColumns</code>.
1758:             */
1759:            int columnNullableUnknown = 2;
1760:
1761:            /**
1762:             * Gets a description of the access rights for a table's columns.
1763:             *
1764:             * <P>Only privileges matching the column name criteria are
1765:             * returned.  They are ordered by COLUMN_NAME and PRIVILEGE.
1766:             *
1767:             * <P>Each privilige description has the following columns:
1768:             *  <OL>
1769:             *  <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1770:             *  <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1771:             *  <LI><B>TABLE_NAME</B> String => table name
1772:             *  <LI><B>COLUMN_NAME</B> String => column name
1773:             *  <LI><B>GRANTOR</B> => grantor of access (may be null)
1774:             *  <LI><B>GRANTEE</B> String => grantee of access
1775:             *  <LI><B>PRIVILEGE</B> String => name of access (SELECT, 
1776:             *      INSERT, UPDATE, REFRENCES, ...)
1777:             *  <LI><B>IS_GRANTABLE</B> String => "YES" if grantee is permitted 
1778:             *      to grant to others; "NO" if not; null if unknown 
1779:             *  </OL>
1780:             *
1781:             * @param catalog a catalog name; "" retrieves those without a
1782:             * catalog; null means drop catalog name from the selection criteria
1783:             * @param schema a schema name; "" retrieves those without a schema
1784:             * @param table a table name
1785:             * @param columnNamePattern a column name pattern 
1786:             * @return ResultSet - each row is a column privilege description
1787:             * @exception SQLException if a database access error occurs
1788:             * @see #getSearchStringEscape 
1789:             */
1790:            public ResultSet getColumnPrivileges(String catalog, String schema,
1791:                    String table, String columnNamePattern) throws SQLException {
1792:                throw new SQLException(
1793:                        "tinySQL does not support column privileges.");
1794:            }
1795:
1796:            /**
1797:             * Gets a description of the access rights for each table available
1798:             * in a catalog. Note that a table privilege applies to one or
1799:             * more columns in the table. It would be wrong to assume that
1800:             * this priviledge applies to all columns (this may be true for
1801:             * some systems but is not true for all.)
1802:             *
1803:             * <P>Only privileges matching the schema and table name
1804:             * criteria are returned.  They are ordered by TABLE_SCHEM,
1805:             * TABLE_NAME, and PRIVILEGE.
1806:             *
1807:             * <P>Each privilige description has the following columns:
1808:             *  <OL>
1809:             *  <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1810:             *  <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1811:             *  <LI><B>TABLE_NAME</B> String => table name
1812:             *  <LI><B>GRANTOR</B> => grantor of access (may be null)
1813:             *  <LI><B>GRANTEE</B> String => grantee of access
1814:             *  <LI><B>PRIVILEGE</B> String => name of access (SELECT, 
1815:             *      INSERT, UPDATE, REFRENCES, ...)
1816:             *  <LI><B>IS_GRANTABLE</B> String => "YES" if grantee is permitted 
1817:             *      to grant to others; "NO" if not; null if unknown 
1818:             *  </OL>
1819:             *
1820:             * @param catalog a catalog name; "" retrieves those without a
1821:             * catalog; null means drop catalog name from the selection criteria
1822:             * @param schemaPattern a schema name pattern; "" retrieves those
1823:             * without a schema
1824:             * @param tableNamePattern a table name pattern 
1825:             * @return ResultSet - each row is a table privilege description
1826:             * @exception SQLException if a database access error occurs
1827:             * @see #getSearchStringEscape 
1828:             */
1829:            public ResultSet getTablePrivileges(String catalog,
1830:                    String schemaPattern, String tableNamePattern)
1831:                    throws SQLException {
1832:                throw new SQLException(
1833:                        "tinySQL does not support table privileges.");
1834:            }
1835:
1836:            /**
1837:             * Gets a description of a table's optimal set of columns that
1838:             * uniquely identifies a row. They are ordered by SCOPE.
1839:             *
1840:             * <P>Each column description has the following columns:
1841:             *  <OL>
1842:             *  <LI><B>SCOPE</B> short => actual scope of result
1843:             *      <UL>
1844:             *      <LI> bestRowTemporary - very temporary, while using row
1845:             *      <LI> bestRowTransaction - valid for remainder of current transaction
1846:             *      <LI> bestRowSession - valid for remainder of current session
1847:             *      </UL>
1848:             *  <LI><B>COLUMN_NAME</B> String => column name
1849:             *  <LI><B>DATA_TYPE</B> short => SQL data type from java.sql.Types
1850:             *  <LI><B>TYPE_NAME</B> String => Data source dependent type name,
1851:             *  for a UDT the type name is fully qualified
1852:             *  <LI><B>COLUMN_SIZE</B> int => precision
1853:             *  <LI><B>BUFFER_LENGTH</B> int => not used
1854:             *  <LI><B>DECIMAL_DIGITS</B> short  => scale
1855:             *  <LI><B>PSEUDO_COLUMN</B> short => is this a pseudo column 
1856:             *      like an Oracle ROWID
1857:             *      <UL>
1858:             *      <LI> bestRowUnknown - may or may not be pseudo column
1859:             *      <LI> bestRowNotPseudo - is NOT a pseudo column
1860:             *      <LI> bestRowPseudo - is a pseudo column
1861:             *      </UL>
1862:             *  </OL>
1863:             *
1864:             * @param catalog a catalog name; "" retrieves those without a
1865:             * catalog; null means drop catalog name from the selection criteria
1866:             * @param schema a schema name; "" retrieves those without a schema
1867:             * @param table a table name
1868:             * @param scope the scope of interest; use same values as SCOPE
1869:             * @param nullable include columns that are nullable?
1870:             * @return ResultSet - each row is a column description 
1871:             * @exception SQLException if a database access error occurs
1872:             */
1873:            public ResultSet getBestRowIdentifier(String catalog,
1874:                    String schema, String table, int scope, boolean nullable)
1875:                    throws SQLException {
1876:                throw new SQLException(
1877:                        "tinySQL does not support best row identifiers.");
1878:            }
1879:
1880:            /**
1881:             * Indicates that the scope of the best row identifier is
1882:             * very temporary, lasting only while the
1883:             * row is being used.
1884:             * A possible value for the column
1885:             * <code>SCOPE</code>
1886:             * in the <code>ResultSet</code> object
1887:             * returned by the method <code>getBestRowIdentifier</code>.
1888:             */
1889:            int bestRowTemporary = 0;
1890:
1891:            /**
1892:             * Indicates that the scope of the best row identifier is
1893:             * the remainder of the current transaction.
1894:             * A possible value for the column
1895:             * <code>SCOPE</code>
1896:             * in the <code>ResultSet</code> object
1897:             * returned by the method <code>getBestRowIdentifier</code>.
1898:             */
1899:            int bestRowTransaction = 1;
1900:
1901:            /**
1902:             * Indicates that the scope of the best row identifier is
1903:             * the remainder of the current session.
1904:             * A possible value for the column
1905:             * <code>SCOPE</code>
1906:             * in the <code>ResultSet</code> object
1907:             * returned by the method <code>getBestRowIdentifier</code>.
1908:             */
1909:            int bestRowSession = 2;
1910:
1911:            /**
1912:             * Indicates that the best row identifier may or may not be a pseudo column.
1913:             * A possible value for the column
1914:             * <code>PSEUDO_COLUMN</code>
1915:             * in the <code>ResultSet</code> object
1916:             * returned by the method <code>getBestRowIdentifier</code>.
1917:             */
1918:            int bestRowUnknown = 0;
1919:
1920:            /**
1921:             * Indicates that the best row identifier is NOT a pseudo column.
1922:             * A possible value for the column
1923:             * <code>PSEUDO_COLUMN</code>
1924:             * in the <code>ResultSet</code> object
1925:             * returned by the method <code>getBestRowIdentifier</code>.
1926:             */
1927:            int bestRowNotPseudo = 1;
1928:
1929:            /**
1930:             * Indicates that the best row identifier is a pseudo column.
1931:             * A possible value for the column
1932:             * <code>PSEUDO_COLUMN</code>
1933:             * in the <code>ResultSet</code> object
1934:             * returned by the method <code>getBestRowIdentifier</code>.
1935:             */
1936:            int bestRowPseudo = 2;
1937:
1938:            /**
1939:             * Gets a description of a table's columns that are automatically
1940:             * updated when any value in a row is updated.  They are
1941:             * unordered.
1942:             *
1943:             * <P>Each column description has the following columns:
1944:             *  <OL>
1945:             *  <LI><B>SCOPE</B> short => is not used
1946:             *  <LI><B>COLUMN_NAME</B> String => column name
1947:             *  <LI><B>DATA_TYPE</B> short => SQL data type from java.sql.Types
1948:             *  <LI><B>TYPE_NAME</B> String => Data source dependent type name
1949:             *  <LI><B>COLUMN_SIZE</B> int => precision
1950:             *  <LI><B>BUFFER_LENGTH</B> int => length of column value in bytes
1951:             *  <LI><B>DECIMAL_DIGITS</B> short  => scale
1952:             *  <LI><B>PSEUDO_COLUMN</B> short => is this a pseudo column 
1953:             *      like an Oracle ROWID
1954:             *      <UL>
1955:             *      <LI> versionColumnUnknown - may or may not be pseudo column
1956:             *      <LI> versionColumnNotPseudo - is NOT a pseudo column
1957:             *      <LI> versionColumnPseudo - is a pseudo column
1958:             *      </UL>
1959:             *  </OL>
1960:             *
1961:             * @param catalog a catalog name; "" retrieves those without a
1962:             * catalog; null means drop catalog name from the selection criteria
1963:             * @param schema a schema name; "" retrieves those without a schema
1964:             * @param table a table name
1965:             * @return ResultSet - each row is a column description 
1966:             * @exception SQLException if a database access error occurs
1967:             */
1968:            public ResultSet getVersionColumns(String catalog, String schema,
1969:                    String table) throws SQLException {
1970:                throw new SQLException(
1971:                        "tinySQL does not support version columns.");
1972:            }
1973:
1974:            /**
1975:             * Indicates that this version column may or may not be a pseudo column.
1976:             * A possible value for the column
1977:             * <code>PSEUDO_COLUMN</code>
1978:             * in the <code>ResultSet</code> object
1979:             * returned by the method <code>getVersionColumns</code>.
1980:             */
1981:            int versionColumnUnknown = 0;
1982:
1983:            /**
1984:             * Indicates that this version column is NOT a pseudo column.
1985:             * A possible value for the column
1986:             * <code>PSEUDO_COLUMN</code>
1987:             * in the <code>ResultSet</code> object
1988:             * returned by the method <code>getVersionColumns</code>.
1989:             */
1990:            int versionColumnNotPseudo = 1;
1991:
1992:            /**
1993:             * Indicates that this version column is a pseudo column.
1994:             * A possible value for the column
1995:             * <code>PSEUDO_COLUMN</code>
1996:             * in the <code>ResultSet</code> object
1997:             * returned by the method <code>getVersionColumns</code>.
1998:             */
1999:            int versionColumnPseudo = 2;
2000:
2001:            /**
2002:             * Gets a description of a table's primary key columns.  They
2003:             * are ordered by COLUMN_NAME.
2004:             *
2005:             * <P>Each primary key column description has the following columns:
2006:             *  <OL>
2007:             *  <LI><B>TABLE_CAT</B> String => table catalog (may be null)
2008:             *  <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
2009:             *  <LI><B>TABLE_NAME</B> String => table name
2010:             *  <LI><B>COLUMN_NAME</B> String => column name
2011:             *  <LI><B>KEY_SEQ</B> short => sequence number within primary key
2012:             *  <LI><B>PK_NAME</B> String => primary key name (may be null)
2013:             *  </OL>
2014:             *
2015:             * @param catalog a catalog name; "" retrieves those without a
2016:             * catalog; null means drop catalog name from the selection criteria
2017:             * @param schema a schema name; "" retrieves those
2018:             * without a schema
2019:             * @param table a table name
2020:             * @return ResultSet - each row is a primary key column description 
2021:             * @exception SQLException if a database access error occurs
2022:             */
2023:            public ResultSet getPrimaryKeys(String catalog, String schema,
2024:                    String table) throws SQLException {
2025:                throw new SQLException("tinySQL does not support primary keys.");
2026:            }
2027:
2028:            /**
2029:             * Gets a description of the primary key columns that are
2030:             * referenced by a table's foreign key columns (the primary keys
2031:             * imported by a table).  They are ordered by PKTABLE_CAT,
2032:             * PKTABLE_SCHEM, PKTABLE_NAME, and KEY_SEQ.
2033:             *
2034:             * <P>Each primary key column description has the following columns:
2035:             *  <OL>
2036:             *  <LI><B>PKTABLE_CAT</B> String => primary key table catalog 
2037:             *      being imported (may be null)
2038:             *  <LI><B>PKTABLE_SCHEM</B> String => primary key table schema
2039:             *      being imported (may be null)
2040:             *  <LI><B>PKTABLE_NAME</B> String => primary key table name
2041:             *      being imported
2042:             *  <LI><B>PKCOLUMN_NAME</B> String => primary key column name
2043:             *      being imported
2044:             *  <LI><B>FKTABLE_CAT</B> String => foreign key table catalog (may be null)
2045:             *  <LI><B>FKTABLE_SCHEM</B> String => foreign key table schema (may be null)
2046:             *  <LI><B>FKTABLE_NAME</B> String => foreign key table name
2047:             *  <LI><B>FKCOLUMN_NAME</B> String => foreign key column name
2048:             *  <LI><B>KEY_SEQ</B> short => sequence number within foreign key
2049:             *  <LI><B>UPDATE_RULE</B> short => What happens to 
2050:             *       foreign key when primary is updated:
2051:             *      <UL>
2052:             *      <LI> importedNoAction - do not allow update of primary 
2053:             *               key if it has been imported
2054:             *      <LI> importedKeyCascade - change imported key to agree 
2055:             *               with primary key update
2056:             *      <LI> importedKeySetNull - change imported key to NULL if 
2057:             *               its primary key has been updated
2058:             *      <LI> importedKeySetDefault - change imported key to default values 
2059:             *               if its primary key has been updated
2060:             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2061:             *                                 (for ODBC 2.x compatibility)
2062:             *      </UL>
2063:             *  <LI><B>DELETE_RULE</B> short => What happens to 
2064:             *      the foreign key when primary is deleted.
2065:             *      <UL>
2066:             *      <LI> importedKeyNoAction - do not allow delete of primary 
2067:             *               key if it has been imported
2068:             *      <LI> importedKeyCascade - delete rows that import a deleted key
2069:             *      <LI> importedKeySetNull - change imported key to NULL if 
2070:             *               its primary key has been deleted
2071:             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2072:             *                                 (for ODBC 2.x compatibility)
2073:             *      <LI> importedKeySetDefault - change imported key to default if 
2074:             *               its primary key has been deleted
2075:             *      </UL>
2076:             *  <LI><B>FK_NAME</B> String => foreign key name (may be null)
2077:             *  <LI><B>PK_NAME</B> String => primary key name (may be null)
2078:             *  <LI><B>DEFERRABILITY</B> short => can the evaluation of foreign key 
2079:             *      constraints be deferred until commit
2080:             *      <UL>
2081:             *      <LI> importedKeyInitiallyDeferred - see SQL92 for definition
2082:             *      <LI> importedKeyInitiallyImmediate - see SQL92 for definition 
2083:             *      <LI> importedKeyNotDeferrable - see SQL92 for definition 
2084:             *      </UL>
2085:             *  </OL>
2086:             *
2087:             * @param catalog a catalog name; "" retrieves those without a
2088:             * catalog; null means drop catalog name from the selection criteria
2089:             * @param schema a schema name; "" retrieves those
2090:             * without a schema
2091:             * @param table a table name
2092:             * @return ResultSet - each row is a primary key column description 
2093:             * @exception SQLException if a database access error occurs
2094:             * @see #getExportedKeys 
2095:             */
2096:            public ResultSet getImportedKeys(String catalog, String schema,
2097:                    String table) throws SQLException {
2098:                throw new SQLException(
2099:                        "tinySQL does not support imported keys.");
2100:            }
2101:
2102:            /**
2103:             * A possible value for the columns <code>UPDATE_RULE</code>
2104:             * and <code>DELETE_RULE</code> in the
2105:             * <code>ResultSet</code> objects returned by the methods
2106:             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2107:             * and <code>getCrossReference</code>.
2108:             * <P>For the column <code>UPDATE_RULE</code>,
2109:             * it indicates that
2110:             * when the primary key is updated, the foreign key (imported key)
2111:             * is changed to agree with it.
2112:             * <P>For the column <code>DELETE_RULE</code>,
2113:             * it indicates that
2114:             * when the primary key is deleted, rows that imported that key
2115:             * are deleted.
2116:             */
2117:            int importedKeyCascade = 0;
2118:
2119:            /**
2120:             * A possible value for the columns <code>UPDATE_RULE</code>
2121:             * and <code>DELETE_RULE</code> in the
2122:             * <code>ResultSet</code> objects returned by the methods
2123:             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2124:             * and <code>getCrossReference</code>.
2125:             * <P>For the column <code>UPDATE_RULE</code>, it indicates that
2126:             * a primary key may not be updated if it has been imported by
2127:             * another table as a foreign key.
2128:             * <P>For the column <code>DELETE_RULE</code>, it indicates that
2129:             * a primary key may not be deleted if it has been imported by
2130:             * another table as a foreign key.
2131:             */
2132:            int importedKeyRestrict = 1;
2133:
2134:            /**
2135:             * A possible value for the columns <code>UPDATE_RULE</code>
2136:             * and <code>DELETE_RULE</code> in the
2137:             * <code>ResultSet</code> objects returned by the methods
2138:             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2139:             * and <code>getCrossReference</code>.
2140:             * <P>For the columns <code>UPDATE_RULE</code>
2141:             * and <code>DELETE_RULE</code>,
2142:             * it indicates that
2143:             * when the primary key is updated or deleted, the foreign key (imported key)
2144:             * is changed to <code>NULL</code>.
2145:             */
2146:            int importedKeySetNull = 2;
2147:
2148:            /**
2149:             * A possible value for the columns <code>UPDATE_RULE</code>
2150:             * and <code>DELETE_RULE</code> in the
2151:             * <code>ResultSet</code> objects returned by the methods
2152:             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2153:             * and <code>getCrossReference</code>.
2154:             * <P>For the columns <code>UPDATE_RULE</code>
2155:             * and <code>DELETE_RULE</code>,
2156:             * it indicates that
2157:             * if the primary key has been imported, it cannot be updated or deleted.
2158:             */
2159:            int importedKeyNoAction = 3;
2160:
2161:            /**
2162:             * A possible value for the columns <code>UPDATE_RULE</code>
2163:             * and <code>DELETE_RULE</code> in the
2164:             * <code>ResultSet</code> objects returned by the methods
2165:             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2166:             * and <code>getCrossReference</code>.
2167:             * <P>For the columns <code>UPDATE_RULE</code>
2168:             * and <code>DELETE_RULE</code>,
2169:             * it indicates that
2170:             * if the primary key is updated or deleted, the foreign key (imported key)
2171:             * is set to the default value.
2172:             */
2173:            int importedKeySetDefault = 4;
2174:
2175:            /**
2176:             * A possible value for the column <code>DEFERRABILITY</code>
2177:             * in the
2178:             * <code>ResultSet</code> objects returned by the methods
2179:             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2180:             * and <code>getCrossReference</code>.
2181:             * <P>Indicates deferrability.  See SQL-92 for a definition.
2182:             */
2183:            int importedKeyInitiallyDeferred = 5;
2184:
2185:            /**
2186:             * A possible value for the column <code>DEFERRABILITY</code>
2187:             * in the
2188:             * <code>ResultSet</code> objects returned by the methods
2189:             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2190:             * and <code>getCrossReference</code>.
2191:             * <P>Indicates deferrability.  See SQL-92 for a definition.
2192:             */
2193:            int importedKeyInitiallyImmediate = 6;
2194:
2195:            /**
2196:             * A possible value for the column <code>DEFERRABILITY</code>
2197:             * in the
2198:             * <code>ResultSet</code> objects returned by the methods
2199:             * <code>getImportedKeys</code>,  <code>getExportedKeys</code>,
2200:             * and <code>getCrossReference</code>.
2201:             * <P>Indicates deferrability.  See SQL-92 for a definition.
2202:             */
2203:            int importedKeyNotDeferrable = 7;
2204:
2205:            /**
2206:             * Gets a description of the foreign key columns that reference a
2207:             * table's primary key columns (the foreign keys exported by a
2208:             * table).  They are ordered by FKTABLE_CAT, FKTABLE_SCHEM,
2209:             * FKTABLE_NAME, and KEY_SEQ.
2210:             *
2211:             * <P>Each foreign key column description has the following columns:
2212:             *  <OL>
2213:             *  <LI><B>PKTABLE_CAT</B> String => primary key table catalog (may be null)
2214:             *  <LI><B>PKTABLE_SCHEM</B> String => primary key table schema (may be null)
2215:             *  <LI><B>PKTABLE_NAME</B> String => primary key table name
2216:             *  <LI><B>PKCOLUMN_NAME</B> String => primary key column name
2217:             *  <LI><B>FKTABLE_CAT</B> String => foreign key table catalog (may be null)
2218:             *      being exported (may be null)
2219:             *  <LI><B>FKTABLE_SCHEM</B> String => foreign key table schema (may be null)
2220:             *      being exported (may be null)
2221:             *  <LI><B>FKTABLE_NAME</B> String => foreign key table name
2222:             *      being exported
2223:             *  <LI><B>FKCOLUMN_NAME</B> String => foreign key column name
2224:             *      being exported
2225:             *  <LI><B>KEY_SEQ</B> short => sequence number within foreign key
2226:             *  <LI><B>UPDATE_RULE</B> short => What happens to 
2227:             *       foreign key when primary is updated:
2228:             *      <UL>
2229:             *      <LI> importedNoAction - do not allow update of primary 
2230:             *               key if it has been imported
2231:             *      <LI> importedKeyCascade - change imported key to agree 
2232:             *               with primary key update
2233:             *      <LI> importedKeySetNull - change imported key to NULL if 
2234:             *               its primary key has been updated
2235:             *      <LI> importedKeySetDefault - change imported key to default values 
2236:             *               if its primary key has been updated
2237:             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2238:             *                                 (for ODBC 2.x compatibility)
2239:             *      </UL>
2240:             *  <LI><B>DELETE_RULE</B> short => What happens to 
2241:             *      the foreign key when primary is deleted.
2242:             *      <UL>
2243:             *      <LI> importedKeyNoAction - do not allow delete of primary 
2244:             *               key if it has been imported
2245:             *      <LI> importedKeyCascade - delete rows that import a deleted key
2246:             *      <LI> importedKeySetNull - change imported key to NULL if 
2247:             *               its primary key has been deleted
2248:             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2249:             *                                 (for ODBC 2.x compatibility)
2250:             *      <LI> importedKeySetDefault - change imported key to default if 
2251:             *               its primary key has been deleted
2252:             *      </UL>
2253:             *  <LI><B>FK_NAME</B> String => foreign key name (may be null)
2254:             *  <LI><B>PK_NAME</B> String => primary key name (may be null)
2255:             *  <LI><B>DEFERRABILITY</B> short => can the evaluation of foreign key 
2256:             *      constraints be deferred until commit
2257:             *      <UL>
2258:             *      <LI> importedKeyInitiallyDeferred - see SQL92 for definition
2259:             *      <LI> importedKeyInitiallyImmediate - see SQL92 for definition 
2260:             *      <LI> importedKeyNotDeferrable - see SQL92 for definition 
2261:             *      </UL>
2262:             *  </OL>
2263:             *
2264:             * @param catalog a catalog name; "" retrieves those without a
2265:             * catalog; null means drop catalog name from the selection criteria
2266:             * @param schema a schema name; "" retrieves those
2267:             * without a schema
2268:             * @param table a table name
2269:             * @return ResultSet - each row is a foreign key column description 
2270:             * @exception SQLException if a database access error occurs
2271:             * @see #getImportedKeys 
2272:             */
2273:            public ResultSet getExportedKeys(String catalog, String schema,
2274:                    String table) throws SQLException {
2275:                throw new SQLException(
2276:                        "tinySQL does not support exported keys.");
2277:            }
2278:
2279:            /**
2280:             * Gets a description of the foreign key columns in the foreign key
2281:             * table that reference the primary key columns of the primary key
2282:             * table (describe how one table imports another's key.) This
2283:             * should normally return a single foreign key/primary key pair
2284:             * (most tables only import a foreign key from a table once.)  They
2285:             * are ordered by FKTABLE_CAT, FKTABLE_SCHEM, FKTABLE_NAME, and
2286:             * KEY_SEQ.
2287:             *
2288:             * <P>Each foreign key column description has the following columns:
2289:             *  <OL>
2290:             *  <LI><B>PKTABLE_CAT</B> String => primary key table catalog (may be null)
2291:             *  <LI><B>PKTABLE_SCHEM</B> String => primary key table schema (may be null)
2292:             *  <LI><B>PKTABLE_NAME</B> String => primary key table name
2293:             *  <LI><B>PKCOLUMN_NAME</B> String => primary key column name
2294:             *  <LI><B>FKTABLE_CAT</B> String => foreign key table catalog (may be null)
2295:             *      being exported (may be null)
2296:             *  <LI><B>FKTABLE_SCHEM</B> String => foreign key table schema (may be null)
2297:             *      being exported (may be null)
2298:             *  <LI><B>FKTABLE_NAME</B> String => foreign key table name
2299:             *      being exported
2300:             *  <LI><B>FKCOLUMN_NAME</B> String => foreign key column name
2301:             *      being exported
2302:             *  <LI><B>KEY_SEQ</B> short => sequence number within foreign key
2303:             *  <LI><B>UPDATE_RULE</B> short => What happens to 
2304:             *       foreign key when primary is updated:
2305:             *      <UL>
2306:             *      <LI> importedNoAction - do not allow update of primary 
2307:             *               key if it has been imported
2308:             *      <LI> importedKeyCascade - change imported key to agree 
2309:             *               with primary key update
2310:             *      <LI> importedKeySetNull - change imported key to NULL if 
2311:             *               its primary key has been updated
2312:             *      <LI> importedKeySetDefault - change imported key to default values 
2313:             *               if its primary key has been updated
2314:             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2315:             *                                 (for ODBC 2.x compatibility)
2316:             *      </UL>
2317:             *  <LI><B>DELETE_RULE</B> short => What happens to 
2318:             *      the foreign key when primary is deleted.
2319:             *      <UL>
2320:             *      <LI> importedKeyNoAction - do not allow delete of primary 
2321:             *               key if it has been imported
2322:             *      <LI> importedKeyCascade - delete rows that import a deleted key
2323:             *      <LI> importedKeySetNull - change imported key to NULL if 
2324:             *               its primary key has been deleted
2325:             *      <LI> importedKeyRestrict - same as importedKeyNoAction 
2326:             *                                 (for ODBC 2.x compatibility)
2327:             *      <LI> importedKeySetDefault - change imported key to default if 
2328:             *               its primary key has been deleted
2329:             *      </UL>
2330:             *  <LI><B>FK_NAME</B> String => foreign key name (may be null)
2331:             *  <LI><B>PK_NAME</B> String => primary key name (may be null)
2332:             *  <LI><B>DEFERRABILITY</B> short => can the evaluation of foreign key 
2333:             *      constraints be deferred until commit
2334:             *      <UL>
2335:             *      <LI> importedKeyInitiallyDeferred - see SQL92 for definition
2336:             *      <LI> importedKeyInitiallyImmediate - see SQL92 for definition 
2337:             *      <LI> importedKeyNotDeferrable - see SQL92 for definition 
2338:             *      </UL>
2339:             *  </OL>
2340:             *
2341:             * @param primaryCatalog a catalog name; "" retrieves those without a
2342:             * catalog; null means drop catalog name from the selection criteria
2343:             * @param primarySchema a schema name; "" retrieves those
2344:             * without a schema
2345:             * @param primaryTable the table name that exports the key
2346:             * @param foreignCatalog a catalog name; "" retrieves those without a
2347:             * catalog; null means drop catalog name from the selection criteria
2348:             * @param foreignSchema a schema name; "" retrieves those
2349:             * without a schema
2350:             * @param foreignTable the table name that imports the key
2351:             * @return ResultSet - each row is a foreign key column description 
2352:             * @exception SQLException if a database access error occurs
2353:             * @see #getImportedKeys 
2354:             */
2355:            public ResultSet getCrossReference(String primaryCatalog,
2356:                    String primarySchema, String primaryTable,
2357:                    String foreignCatalog, String foreignSchema,
2358:                    String foreignTable) throws SQLException {
2359:                throw new SQLException(
2360:                        "tinySQL does not support cross reference.");
2361:            }
2362:
2363:            /**
2364:             * Gets a description of all the standard SQL types supported by
2365:             * this database. They are ordered by DATA_TYPE and then by how
2366:             * closely the data type maps to the corresponding JDBC SQL type.
2367:             *
2368:             * <P>Each type description has the following columns:
2369:             *  <OL>
2370:             *  <LI><B>TYPE_NAME</B> String => Type name
2371:             *  <LI><B>DATA_TYPE</B> short => SQL data type from java.sql.Types
2372:             *  <LI><B>PRECISION</B> int => maximum precision
2373:             *  <LI><B>LITERAL_PREFIX</B> String => prefix used to quote a literal 
2374:             *      (may be null)
2375:             *  <LI><B>LITERAL_SUFFIX</B> String => suffix used to quote a literal 
2376:                    (may be null)
2377:             *  <LI><B>CREATE_PARAMS</B> String => parameters used in creating 
2378:             *      the type (may be null)
2379:             *  <LI><B>NULLABLE</B> short => can you use NULL for this type?
2380:             *      <UL>
2381:             *      <LI> typeNoNulls - does not allow NULL values
2382:             *      <LI> typeNullable - allows NULL values
2383:             *      <LI> typeNullableUnknown - nullability unknown
2384:             *      </UL>
2385:             *  <LI><B>CASE_SENSITIVE</B> boolean=> is it case sensitive?
2386:             *  <LI><B>SEARCHABLE</B> short => can you use "WHERE" based on this type:
2387:             *      <UL>
2388:             *      <LI> typePredNone - No support
2389:             *      <LI> typePredChar - Only supported with WHERE .. LIKE
2390:             *      <LI> typePredBasic - Supported except for WHERE .. LIKE
2391:             *      <LI> typeSearchable - Supported for all WHERE ..
2392:             *      </UL>
2393:             *  <LI><B>UNSIGNED_ATTRIBUTE</B> boolean => is it unsigned?
2394:             *  <LI><B>FIXED_PREC_SCALE</B> boolean => can it be a money value?
2395:             *  <LI><B>AUTO_INCREMENT</B> boolean => can it be used for an 
2396:             *      auto-increment value?
2397:             *  <LI><B>LOCAL_TYPE_NAME</B> String => localized version of type name 
2398:             *      (may be null)
2399:             *  <LI><B>MINIMUM_SCALE</B> short => minimum scale supported
2400:             *  <LI><B>MAXIMUM_SCALE</B> short => maximum scale supported
2401:             *  <LI><B>SQL_DATA_TYPE</B> int => unused
2402:             *  <LI><B>SQL_DATETIME_SUB</B> int => unused
2403:             *  <LI><B>NUM_PREC_RADIX</B> int => usually 2 or 10
2404:             *  </OL>
2405:             *
2406:             * @return ResultSet - each row is a SQL type description 
2407:             * @exception SQLException if a database access error occurs
2408:             */
2409:            public ResultSet getTypeInfo() throws SQLException {
2410:                throw new SQLException(
2411:                        "tinySQL getTypeInfo not yet implemented.");
2412:            }
2413:
2414:            /**
2415:             * A possible value for column <code>NULLABLE</code> in the
2416:             * <code>ResultSet</code> object returned by the method
2417:             * <code>getTypeInfo</code>.
2418:             * <p>Indicates that a <code>NULL</code> value is NOT allowed for this
2419:             * data type.
2420:             */
2421:            int typeNoNulls = 0;
2422:
2423:            /**
2424:             * A possible value for column <code>NULLABLE</code> in the
2425:             * <code>ResultSet</code> object returned by the method
2426:             * <code>getTypeInfo</code>.
2427:             * <p>Indicates that a <code>NULL</code> value is allowed for this
2428:             * data type.
2429:             */
2430:            int typeNullable = 1;
2431:
2432:            /**
2433:             * A possible value for column <code>NULLABLE</code> in the
2434:             * <code>ResultSet</code> object returned by the method
2435:             * <code>getTypeInfo</code>.
2436:             * <p>Indicates that it is not known whether a <code>NULL</code> value 
2437:             * is allowed for this data type.
2438:             */
2439:            int typeNullableUnknown = 2;
2440:
2441:            /**
2442:             * A possible value for column <code>SEARCHABLE</code> in the
2443:             * <code>ResultSet</code> object returned by the method
2444:             * <code>getTypeInfo</code>.
2445:             * <p>Indicates that <code>WHERE</code> search clauses are not supported
2446:             * for this type.
2447:             */
2448:            int typePredNone = 0;
2449:
2450:            /**
2451:             * A possible value for column <code>SEARCHABLE</code> in the
2452:             * <code>ResultSet</code> object returned by the method
2453:             * <code>getTypeInfo</code>.
2454:             * <p>Indicates that the only <code>WHERE</code> search clause that can
2455:             * be based on this type is <code>WHERE . . .LIKE</code>.
2456:             */
2457:            int typePredChar = 1;
2458:
2459:            /**
2460:             * A possible value for column <code>SEARCHABLE</code> in the
2461:             * <code>ResultSet</code> object returned by the method
2462:             * <code>getTypeInfo</code>.
2463:             * <p>Indicates that one can base all <code>WHERE</code> search clauses 
2464:             * except <code>WHERE . . .LIKE</code> on this data type.
2465:             */
2466:            int typePredBasic = 2;
2467:
2468:            /**
2469:             * A possible value for column <code>SEARCHABLE</code> in the
2470:             * <code>ResultSet</code> object returned by the method
2471:             * <code>getTypeInfo</code>.
2472:             * <p>Indicates that all <code>WHERE</code> search clauses can be 
2473:             * based on this type.
2474:             */
2475:            int typeSearchable = 3;
2476:
2477:            /**
2478:             * Gets a description of a table's indices and statistics. They are
2479:             * ordered by NON_UNIQUE, TYPE, INDEX_NAME, and ORDINAL_POSITION.
2480:             *
2481:             * <P>Each index column description has the following columns:
2482:             *  <OL>
2483:             *  <LI><B>TABLE_CAT</B> String => table catalog (may be null)
2484:             *  <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
2485:             *  <LI><B>TABLE_NAME</B> String => table name
2486:             *  <LI><B>NON_UNIQUE</B> boolean => Can index values be non-unique? 
2487:             *      false when TYPE is tableIndexStatistic
2488:             *  <LI><B>INDEX_QUALIFIER</B> String => index catalog (may be null); 
2489:             *      null when TYPE is tableIndexStatistic
2490:             *  <LI><B>INDEX_NAME</B> String => index name; null when TYPE is 
2491:             *      tableIndexStatistic
2492:             *  <LI><B>TYPE</B> short => index type:
2493:             *      <UL>
2494:             *      <LI> tableIndexStatistic - this identifies table statistics that are
2495:             *           returned in conjuction with a table's index descriptions
2496:             *      <LI> tableIndexClustered - this is a clustered index
2497:             *      <LI> tableIndexHashed - this is a hashed index
2498:             *      <LI> tableIndexOther - this is some other style of index
2499:             *      </UL>
2500:             *  <LI><B>ORDINAL_POSITION</B> short => column sequence number 
2501:             *      within index; zero when TYPE is tableIndexStatistic
2502:             *  <LI><B>COLUMN_NAME</B> String => column name; null when TYPE is 
2503:             *      tableIndexStatistic
2504:             *  <LI><B>ASC_OR_DESC</B> String => column sort sequence, "A" => ascending, 
2505:             *      "D" => descending, may be null if sort sequence is not supported; 
2506:             *      null when TYPE is tableIndexStatistic 
2507:             *  <LI><B>CARDINALITY</B> int => When TYPE is tableIndexStatistic, then 
2508:             *      this is the number of rows in the table; otherwise, it is the 
2509:             *      number of unique values in the index.
2510:             *  <LI><B>PAGES</B> int => When TYPE is  tableIndexStatisic then 
2511:             *      this is the number of pages used for the table, otherwise it 
2512:             *      is the number of pages used for the current index.
2513:             *  <LI><B>FILTER_CONDITION</B> String => Filter condition, if any.  
2514:             *      (may be null)
2515:             *  </OL>
2516:             *
2517:             * @param catalog a catalog name; "" retrieves those without a
2518:             * catalog; null means drop catalog name from the selection criteria
2519:             * @param schema a schema name; "" retrieves those without a schema
2520:             * @param table a table name  
2521:             * @param unique when true, return only indices for unique values; 
2522:             *     when false, return indices regardless of whether unique or not 
2523:             * @param approximate when true, result is allowed to reflect approximate 
2524:             *     or out of data values; when false, results are requested to be 
2525:             *     accurate
2526:             * @return ResultSet - each row is an index column description 
2527:             * @exception SQLException if a database access error occurs
2528:             */
2529:            public ResultSet getIndexInfo(String catalog, String schema,
2530:                    String table, boolean unique, boolean approximate)
2531:                    throws SQLException {
2532:                throw new SQLException("tinySQL does not support index infos.");
2533:            }
2534:
2535:            /**
2536:             * A possible value for column <code>TYPE</code> in the
2537:             * <code>ResultSet</code> object returned by the method
2538:             * <code>getIndexInfo</code>.
2539:             * <P>Indicates that this column contains table statistics that
2540:             * are returned in conjunction with a table's index descriptions.
2541:             */
2542:            short tableIndexStatistic = 0;
2543:
2544:            /**
2545:             * A possible value for column <code>TYPE</code> in the
2546:             * <code>ResultSet</code> object returned by the method
2547:             * <code>getIndexInfo</code>.
2548:             * <P>Indicates that this table index is a clustered index.
2549:             */
2550:            short tableIndexClustered = 1;
2551:
2552:            /**
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:             * <P>Indicates that this table index is a hashed index.
2557:             */
2558:            short tableIndexHashed = 2;
2559:
2560:            /**
2561:             * A possible value for column <code>TYPE</code> in the
2562:             * <code>ResultSet</code> object returned by the method
2563:             * <code>getIndexInfo</code>.
2564:             * <P>Indicates that this table index is not a clustered
2565:             * index, a hashed index, or table statistics;
2566:             * it is something other than these.
2567:             */
2568:            short tableIndexOther = 3;
2569:
2570:            //--------------------------JDBC 2.0-----------------------------
2571:
2572:            /**
2573:             * JDBC 2.0
2574:             *
2575:             * Does the database support the given result set type?
2576:             *
2577:             * @param type defined in <code>java.sql.ResultSet</code>
2578:             * @return <code>true</code> if so; <code>false</code> otherwise 
2579:             * @exception SQLException if a database access error occurs
2580:             * @see Connection
2581:             */
2582:            public boolean supportsResultSetType(int type) {
2583:                return false;
2584:            }
2585:
2586:            /**
2587:             * JDBC 2.0
2588:             *
2589:             * Does the database support the concurrency type in combination
2590:             * with the given result set type?
2591:             *
2592:             * @param type defined in <code>java.sql.ResultSet</code>
2593:             * @param concurrency 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:             */
2598:            public boolean supportsResultSetConcurrency(int type,
2599:                    int concurrency) {
2600:                return false;
2601:            }
2602:
2603:            /**
2604:             * JDBC 2.0
2605:             *
2606:             * Indicates whether a result set's own updates are visible.
2607:             *
2608:             * @param result set type, i.e. ResultSet.TYPE_XXX
2609:             * @return <code>true</code> if updates are visible for the result set type;
2610:             *        <code>false</code> otherwise
2611:             * @exception SQLException if a database access error occurs
2612:             */
2613:            public boolean ownUpdatesAreVisible(int type) {
2614:                return false;
2615:            }
2616:
2617:            /**
2618:             * JDBC 2.0
2619:             *
2620:             * Indicates whether a result set's own deletes are visible.
2621:             *
2622:             * @param result set type, i.e. ResultSet.TYPE_XXX
2623:             * @return <code>true</code> if deletes are visible for the result set type;
2624:             *        <code>false</code> otherwise
2625:             * @exception SQLException if a database access error occurs
2626:             */
2627:            public boolean ownDeletesAreVisible(int type) {
2628:                return false;
2629:            }
2630:
2631:            /**
2632:             * JDBC 2.0
2633:             *
2634:             * Indicates whether a result set's own inserts are visible.
2635:             *
2636:             * @param result set type, i.e. ResultSet.TYPE_XXX
2637:             * @return <code>true</code> if inserts are visible for the result set type;
2638:             *        <code>false</code> otherwise
2639:             * @exception SQLException if a database access error occurs
2640:             */
2641:            public boolean ownInsertsAreVisible(int type) {
2642:                return false;
2643:            }
2644:
2645:            /**
2646:             * JDBC 2.0
2647:             *
2648:             * Indicates whether updates made by others are visible.
2649:             *
2650:             * @param result set type, i.e. ResultSet.TYPE_XXX
2651:             * @return <code>true</code> if updates made by others
2652:             * are visible for the result set type;
2653:             *        <code>false</code> otherwise
2654:             * @exception SQLException if a database access error occurs
2655:             */
2656:            public boolean othersUpdatesAreVisible(int type) {
2657:                return false;
2658:            }
2659:
2660:            /**
2661:             * JDBC 2.0
2662:             *
2663:             * Indicates whether deletes made by others are visible.
2664:             *
2665:             * @param result set type, i.e. ResultSet.TYPE_XXX
2666:             * @return <code>true</code> if deletes made by others
2667:             * are visible for the result set type;
2668:             *        <code>false</code> otherwise
2669:             * @exception SQLException if a database access error occurs
2670:             */
2671:            public boolean othersDeletesAreVisible(int type) {
2672:                return false;
2673:            }
2674:
2675:            /**
2676:             * JDBC 2.0
2677:             *
2678:             * Indicates whether inserts made by others are visible.
2679:             *
2680:             * @param result set type, i.e. ResultSet.TYPE_XXX
2681:             * @return true if updates are visible for the result set type
2682:             * @return <code>true</code> if inserts made by others
2683:             * are visible for the result set type;
2684:             *        <code>false</code> otherwise
2685:             * @exception SQLException if a database access error occurs
2686:             */
2687:            public boolean othersInsertsAreVisible(int type) {
2688:                return false;
2689:            }
2690:
2691:            /**
2692:             * JDBC 2.0
2693:             *
2694:             * Indicates whether or not a visible row update can be detected by 
2695:             * calling the method <code>ResultSet.rowUpdated</code>.
2696:             *
2697:             * @param result set type, i.e. ResultSet.TYPE_XXX
2698:             * @return <code>true</code> if changes are detected by the result set type;
2699:             *         <code>false</code> otherwise
2700:             * @exception SQLException if a database access error occurs
2701:             */
2702:            public boolean updatesAreDetected(int type) {
2703:                return false;
2704:            }
2705:
2706:            /**
2707:             * JDBC 2.0
2708:             *
2709:             * Indicates whether or not a visible row delete can be detected by 
2710:             * calling ResultSet.rowDeleted().  If deletesAreDetected()
2711:             * returns false, then deleted rows are removed from the result set.
2712:             *
2713:             * @param result set type, i.e. ResultSet.TYPE_XXX
2714:             * @return true if changes are detected by the resultset type
2715:             * @exception SQLException if a database access error occurs
2716:             */
2717:            public boolean deletesAreDetected(int type) {
2718:                return false;
2719:            }
2720:
2721:            /**
2722:             * JDBC 2.0
2723:             *
2724:             * Indicates whether or not a visible row insert can be detected
2725:             * by calling ResultSet.rowInserted().
2726:             *
2727:             * @param result set type, i.e. ResultSet.TYPE_XXX
2728:             * @return true if changes are detected by the resultset type
2729:             * @exception SQLException if a database access error occurs
2730:             */
2731:            public boolean insertsAreDetected(int type) {
2732:                return false;
2733:            }
2734:
2735:            /**
2736:             * JDBC 2.0
2737:             *
2738:             * Indicates whether the driver supports batch updates.
2739:             * @return true if the driver supports batch updates; false otherwise
2740:             */
2741:            public boolean supportsBatchUpdates() {
2742:                return false;
2743:            }
2744:
2745:            /**
2746:             * JDBC 2.0
2747:             *
2748:             * Gets a description of the user-defined types defined in a particular
2749:             * schema.  Schema-specific UDTs may have type JAVA_OBJECT, STRUCT, 
2750:             * or DISTINCT.
2751:             *
2752:             * <P>Only types matching the catalog, schema, type name and type  
2753:             * criteria are returned.  They are ordered by DATA_TYPE, TYPE_SCHEM 
2754:             * and TYPE_NAME.  The type name parameter may be a fully-qualified 
2755:             * name.  In this case, the catalog and schemaPattern parameters are
2756:             * ignored.
2757:             *
2758:             * <P>Each type description has the following columns:
2759:             *  <OL>
2760:             *  <LI><B>TYPE_CAT</B> String => the type's catalog (may be null)
2761:             *  <LI><B>TYPE_SCHEM</B> String => type's schema (may be null)
2762:             *  <LI><B>TYPE_NAME</B> String => type name
2763:             *  <LI><B>CLASS_NAME</B> String => Java class name
2764:             *  <LI><B>DATA_TYPE</B> String => type value defined in java.sql.Types.  
2765:             *  One of JAVA_OBJECT, STRUCT, or DISTINCT
2766:             *  <LI><B>REMARKS</B> String => explanatory comment on the type
2767:             *  </OL>
2768:             *
2769:             * <P><B>Note:</B> If the driver does not support UDTs, an empty
2770:             * result set is returned.
2771:             *
2772:             * @param catalog a catalog name; "" retrieves those without a
2773:             * catalog; null means drop catalog name from the selection criteria
2774:             * @param schemaPattern a schema name pattern; "" retrieves those
2775:             * without a schema
2776:             * @param typeNamePattern a type name pattern; may be a fully-qualified
2777:             * name
2778:             * @param types a list of user-named types to include (JAVA_OBJECT, 
2779:             * STRUCT, or DISTINCT); null returns all types 
2780:             * @return ResultSet - each row is a type description
2781:             * @exception SQLException if a database access error occurs
2782:             */
2783:            public ResultSet getUDTs(String catalog, String schemaPattern,
2784:                    String typeNamePattern, int[] types) throws SQLException {
2785:                throw new SQLException("tinySQL does not support getUDTs.");
2786:            }
2787:
2788:            /**
2789:             * JDBC 2.0
2790:             * Retrieves the connection that produced this metadata object.
2791:             *
2792:             * @return the connection that produced this metadata object
2793:             */
2794:            public Connection getConnection() {
2795:                return connection;
2796:            }
2797:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.