Source for java.sql.DatabaseMetaData

   1: /* DatabaseMetaData.java -- Information about the database itself.
   2:    Copyright (C) 1999, 2000, 2001, 2002, 2006 Free Software Foundation, Inc.
   3: 
   4: This file is part of GNU Classpath.
   5: 
   6: GNU Classpath is free software; you can redistribute it and/or modify
   7: it under the terms of the GNU General Public License as published by
   8: the Free Software Foundation; either version 2, or (at your option)
   9: any later version.
  10:  
  11: GNU Classpath is distributed in the hope that it will be useful, but
  12: WITHOUT ANY WARRANTY; without even the implied warranty of
  13: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  14: General Public License for more details.
  15: 
  16: You should have received a copy of the GNU General Public License
  17: along with GNU Classpath; see the file COPYING.  If not, write to the
  18: Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
  19: 02110-1301 USA.
  20: 
  21: Linking this library statically or dynamically with other modules is
  22: making a combined work based on this library.  Thus, the terms and
  23: conditions of the GNU General Public License cover the whole
  24: combination.
  25: 
  26: As a special exception, the copyright holders of this library give you
  27: permission to link this library with independent modules to produce an
  28: executable, regardless of the license terms of these independent
  29: modules, and to copy and distribute the resulting executable under
  30: terms of your choice, provided that you also meet, for each linked
  31: independent module, the terms and conditions of the license of that
  32: module.  An independent module is a module which is not derived from
  33: or based on this library.  If you modify this library, you may extend
  34: this exception to your version of the library, but you are not
  35: obligated to do so.  If you do not wish to do so, delete this
  36: exception statement from your version. */
  37: 
  38: package java.sql;
  39: 
  40: public interface DatabaseMetaData 
  41: {
  42:   /**
  43:    * It is unknown whether or not the procedure returns a result.
  44:    */
  45:   int procedureResultUnknown = 0;
  46: 
  47:   /**
  48:    * The procedure does not return a result.
  49:    */
  50:   int procedureNoResult = 1;
  51: 
  52:   /**
  53:    * The procedure returns a result.
  54:    */
  55:   int procedureReturnsResult = 2;
  56: 
  57:   /**
  58:    * The column type is unknown.
  59:    */
  60:   int procedureColumnUnknown = 0;
  61: 
  62:   /**
  63:    * The column type is input.
  64:    */
  65:   int procedureColumnIn = 1;
  66: 
  67:   /**
  68:    * The column type is input/output.
  69:    */
  70:   int procedureColumnInOut = 2;
  71: 
  72:   /**
  73:    * The column type is output
  74:    */
  75:   int procedureColumnOut = 4;
  76: 
  77:   /**
  78:    * The column is used for return values.
  79:    */
  80:   int procedureColumnReturn = 5;
  81: 
  82:   /**
  83:    * The column is used for storing results
  84:    */
  85:   int procedureColumnResult = 3;
  86: 
  87:   /**
  88:    * NULL values are not allowed.
  89:    */
  90:   int procedureNoNulls = 0;
  91: 
  92:   /**
  93:    * NULL values are allowed.
  94:    */
  95:   int procedureNullable = 1;
  96: 
  97:   /**
  98:    * It is unknown whether or not NULL values are allowed.
  99:    */
 100:   int procedureNullableUnknown = 2;
 101: 
 102:   /**
 103:    * The column does not allow NULL
 104:    */
 105:   int columnNoNulls = 0;
 106: 
 107:   /**
 108:    * The column does allow NULL
 109:    */
 110:   int columnNullable = 1;
 111: 
 112:   /**
 113:    * It is unknown whether or not the column allows NULL
 114:    */
 115:   int columnNullableUnknown = 2;
 116: 
 117:   /**
 118:    * The best row's scope is only guaranteed to be valid so long as the
 119:    * row is actually being used.
 120:    */
 121:   int bestRowTemporary = 0;
 122: 
 123:   /**
 124:    * The best row identifier is valid to the end of the transaction.
 125:    */
 126:   int bestRowTransaction = 1;
 127: 
 128:   /**
 129:    * The best row identifier is valid to the end of the session.
 130:    */
 131:   int bestRowSession = 2;
 132: 
 133:   /**
 134:    * The best row may or may not be a pseudo-column.
 135:    */
 136:   int bestRowUnknown = 0;
 137: 
 138:   /**
 139:    * The best row identifier is not a pseudo-column.
 140:    */
 141:   int bestRowNotPseudo = 1;
 142: 
 143:   /**
 144:    * The best row identifier is a pseudo-column.
 145:    */
 146:   int bestRowPseudo = 2;
 147: 
 148:   /**
 149:    * It is unknown whether or not the version column is a pseudo-column.
 150:    */
 151:   int versionColumnUnknown = 0;
 152: 
 153:   /**
 154:    * The version column is not a pseudo-column
 155:    */
 156:   int versionColumnNotPseudo = 1;
 157: 
 158:   /**
 159:    * The version column is a pseudo-column
 160:    */
 161:   int versionColumnPseudo = 2;
 162: 
 163:   /**
 164:    * Foreign key changes are cascaded in updates or deletes.
 165:    */
 166:   int importedKeyCascade = 0;
 167: 
 168:   /**
 169:    * Column may not be updated or deleted in use as a foreign key.
 170:    */
 171:   int importedKeyRestrict = 1;
 172: 
 173:   /**
 174:    * When primary key is updated or deleted, the foreign key is set to NULL.
 175:    */
 176:   int importedKeySetNull = 2;
 177: 
 178:   /**
 179:    * If the primary key is a foreign key, it cannot be udpated or deleted.
 180:    */
 181:   int importedKeyNoAction = 3;
 182: 
 183:   /**
 184:    * If the primary key is updated or deleted, the foreign key is set to
 185:    * a default value.
 186:    */
 187:   int importedKeySetDefault = 4;
 188: 
 189:   /**
 190:    * Wish I knew what this meant.
 191:    */
 192:   int importedKeyInitiallyDeferred = 5;
 193: 
 194:   /**
 195:    * Wish I knew what this meant.
 196:    */
 197:   int importedKeyInitiallyImmediate = 6;
 198: 
 199:   /**
 200:    * Wish I knew what this meant.
 201:    */
 202:   int importedKeyNotDeferrable = 7;
 203: 
 204:   /**
 205:    * A NULL value is not allowed for this data type.
 206:    */
 207:   int typeNoNulls = 0;
 208: 
 209:   /**
 210:    * A NULL value is allowed for this data type.
 211:    */
 212:   int typeNullable = 1;
 213: 
 214:   /**
 215:    * It is unknown whether or not NULL values are allowed for this data type.
 216:    */
 217:   int typeNullableUnknown = 2;
 218: 
 219:   /**
 220:    * Where clauses are not supported for this type.
 221:    */
 222:   int typePredNone = 0;
 223: 
 224:   /**
 225:    * Only "WHERE..LIKE" style WHERE clauses are allowed on this data type.
 226:    */
 227:   int typePredChar = 1;
 228: 
 229:   /**
 230:    * All WHERE clauses except "WHERE..LIKE" style are allowed on this data type.
 231:    */
 232:   int typePredBasic = 2;
 233: 
 234:   /**
 235:    * Any type of WHERE clause is allowed for this data type.
 236:    */
 237:   int typeSearchable = 3;
 238: 
 239:   /**
 240:    * This column contains table statistics.
 241:    */
 242:   short tableIndexStatistic = 0;
 243: 
 244:   /**
 245:    * This table index is clustered.
 246:    */
 247:   short tableIndexClustered = 1;
 248: 
 249:   /**
 250:    * This table index is hashed.
 251:    */
 252:   short tableIndexHashed = 2;
 253: 
 254:   /**
 255:    * This table index is of another type.
 256:    */
 257:   short tableIndexOther = 3;
 258: 
 259:   /**
 260:    * A NULL value is not allowed for this attribute.
 261:    */
 262:   short attributeNoNulls = 0;
 263: 
 264:   /**
 265:    * A NULL value is allowed for this attribute.
 266:    */
 267:   short attributeNullable = 1;
 268: 
 269:   /**
 270:    * It is unknown whether or not NULL values are allowed for this attribute.
 271:    */
 272:   short attributeNullableUnknown = 2;
 273: 
 274:   int sqlStateXOpen = 1;
 275: 
 276:   int sqlStateSQL99 = 2;
 277: 
 278:   /**
 279:    * This method tests whether or not all the procedures returned by
 280:    * the <code>getProcedures</code> method can be called by this user.
 281:    *
 282:    * @return <code>true</code> if all the procedures can be called,
 283:    * <code>false</code> otherwise.
 284:    * @exception SQLException If an error occurs.
 285:    */
 286:   boolean allProceduresAreCallable() throws SQLException;
 287: 
 288:   /**
 289:    * This method tests whether or not all the table returned by the
 290:    * <code>getTables</code> method can be selected by this user.
 291:    *
 292:    * @return <code>true</code> if all the procedures can be called,
 293:    * <code>false</code> otherwise.
 294:    *
 295:    * @exception SQLException If an error occurs.
 296:    */
 297:   boolean allTablesAreSelectable() throws SQLException;
 298: 
 299:   /**
 300:    * This method returns the URL for this database.
 301:    *
 302:    * @return The URL string for this database, or <code>null</code> if it
 303:    *         is not known.
 304:    * @exception SQLException If an error occurs.
 305:    */
 306:   String getURL() throws SQLException;
 307: 
 308:   /**
 309:    * This method returns the database username for this connection.
 310:    *
 311:    * @return The database username.
 312:    * @exception SQLException If an error occurs.
 313:    */
 314:   String getUserName() throws SQLException;
 315: 
 316:   /**
 317:    * This method tests whether or not the database is in read only mode.
 318:    *
 319:    * @return <code>true</code> if the database is in read only mode,
 320:    *         <code>false</code> otherwise.
 321:    * @exception SQLException If an error occurs.
 322:    */
 323:   boolean isReadOnly() throws SQLException;
 324: 
 325:   /**
 326:    * This method tests whether or not NULL's sort as high values.
 327:    *
 328:    * @return <code>true</code> if NULL's sort as high values, <code>false</code>
 329:    *         otherwise.
 330:    * @exception SQLException If an error occurs.
 331:    */
 332:   boolean nullsAreSortedHigh() throws SQLException;
 333: 
 334:   /**
 335:    * This method tests whether or not NULL's sort as low values.
 336:    *
 337:    * @return <code>true</code> if NULL's sort as low values, <code>false</code>
 338:    * otherwise.
 339:    * @exception SQLException If an error occurs.
 340:    */
 341:   boolean nullsAreSortedLow() throws SQLException;
 342: 
 343:   /**
 344:    * This method tests whether or not NULL's sort as high values.
 345:    *
 346:    * @return <code>true</code> if NULL's sort as high values, <code>false</code>
 347:    * otherwise.
 348:    * @exception SQLException If an error occurs.
 349:    */
 350:   boolean nullsAreSortedAtStart() throws SQLException;
 351: 
 352:   /**
 353:    * This method test whether or not NULL's are sorted to the end
 354:    * of the list regardless of ascending or descending sort order.
 355:    *
 356:    * @return <code>true</code> if NULL's always sort to the end,
 357:    * <code>false</code> otherwise.
 358:    * @exception SQLException If an error occurs.
 359:    */
 360:   boolean nullsAreSortedAtEnd() throws SQLException;
 361: 
 362:   /**
 363:    * This method returns the name of the database product.
 364:    *
 365:    * @return The database product.
 366:    * @exception SQLException If an error occurs.
 367:    */
 368:   String getDatabaseProductName() throws SQLException;
 369: 
 370:   /**
 371:    * This method returns the version of the database product.
 372:    *
 373:    * @return The version of the database product.
 374:    * @exception SQLException If an error occurs.
 375:    */
 376:   String getDatabaseProductVersion() throws SQLException;
 377: 
 378:   /**
 379:    * This method returns the name of the JDBC driver.
 380:    *
 381:    * @return The name of the JDBC driver.
 382:    * @exception SQLException If an error occurs.
 383:    */
 384:   String getDriverName() throws SQLException;
 385: 
 386:   /**
 387:    * This method returns the version of the JDBC driver.
 388:    *
 389:    * @return The version of the JDBC driver.
 390:    * @exception SQLException If an error occurs.
 391:    */
 392:   String getDriverVersion() throws SQLException;
 393: 
 394:   /**
 395:    * This method returns the major version number of the JDBC driver.
 396:    *
 397:    * @return The major version number of the JDBC driver.
 398:    */
 399:   int getDriverMajorVersion();
 400: 
 401:   /**
 402:    * This method returns the minor version number of the JDBC driver.
 403:    *
 404:    * @return The minor version number of the JDBC driver.
 405:    */
 406:   int getDriverMinorVersion();
 407: 
 408:   /**
 409:    * This method tests whether or not the database uses local files to
 410:    * store tables.
 411:    *
 412:    * @return <code>true</code> if the database uses local files, 
 413:    * <code>false</code> otherwise.
 414:    *
 415:    * @exception SQLException If an error occurs.
 416:    */
 417:   boolean usesLocalFiles() throws SQLException;
 418: 
 419:   /**
 420:    * This method tests whether or not the database uses a separate file for
 421:    * each table.
 422:    *
 423:    * @return <code>true</code> if the database uses a separate file for each
 424:    * table <code>false</code> otherwise.
 425:    *
 426:    * @exception SQLException If an error occurs.
 427:    */
 428:   boolean usesLocalFilePerTable() throws SQLException;
 429: 
 430:   /**
 431:    * This method tests whether or not the database supports identifiers
 432:    * with mixed case.
 433:    *
 434:    * @return <code>true</code> if the database supports mixed case identifiers,
 435:    * <code>false</code> otherwise.
 436:    *
 437:    * @exception SQLException If an error occurs.
 438:    */
 439:   boolean supportsMixedCaseIdentifiers() throws SQLException;
 440: 
 441:   /**
 442:    * This method tests whether or not the database treats mixed case
 443:    * identifiers as all upper case.
 444:    *
 445:    * @return <code>true</code> if the database treats all identifiers as
 446:    *         upper case, <code>false</code> otherwise.
 447:    * @exception SQLException If an error occurs.
 448:    */
 449:   boolean storesUpperCaseIdentifiers() throws SQLException;
 450: 
 451:   /**
 452:    * This method tests whether or not the database treats mixed case
 453:    * identifiers as all lower case.
 454:    *
 455:    * @return <code>true</code> if the database treats all identifiers as
 456:    *         lower case, <code>false</code> otherwise.
 457:    * @exception SQLException If an error occurs.
 458:    */
 459:   boolean storesLowerCaseIdentifiers() throws SQLException;
 460: 
 461:   /**
 462:    * This method tests whether or not the database stores mixed case 
 463:    * identifers even if it treats them as case insensitive.
 464:    *
 465:    * @return <code>true</code> if the database stores mixed case identifiers,
 466:    *         <code>false</code> otherwise.
 467:    * @exception SQLException If an error occurs.
 468:    */
 469:   boolean storesMixedCaseIdentifiers() throws SQLException;
 470: 
 471:   /**
 472:    * This method tests whether or not the database supports quoted identifiers
 473:    * with mixed case.
 474:    *
 475:    * @return <code>true</code> if the database supports mixed case quoted
 476:    *         identifiers, <code>false</code> otherwise.
 477:    * @exception SQLException If an error occurs.
 478:    */
 479:   boolean supportsMixedCaseQuotedIdentifiers() throws SQLException;
 480: 
 481:   /**
 482:    * This method tests whether or not the database treats mixed case
 483:    * quoted identifiers as all upper case.
 484:    *
 485:    * @return <code>true</code> if the database treats all quoted identifiers 
 486:    *         as upper case, <code>false</code> otherwise.
 487:    * @exception SQLException If an error occurs.
 488:    */
 489:   boolean storesUpperCaseQuotedIdentifiers() throws SQLException;
 490: 
 491:   /**
 492:    * This method tests whether or not the database treats mixed case
 493:    * quoted identifiers as all lower case.
 494:    *
 495:    * @return <code>true</code> if the database treats all quoted identifiers 
 496:    *         as lower case, <code>false</code> otherwise.
 497:    * @exception SQLException If an error occurs.
 498:    */
 499:   boolean storesLowerCaseQuotedIdentifiers() throws SQLException;
 500: 
 501:   /**
 502:    * This method tests whether or not the database stores mixed case 
 503:    * quoted identifers even if it treats them as case insensitive.
 504:    *
 505:    * @return <code>true</code> if the database stores mixed case quoted 
 506:    *         identifiers, <code>false</code> otherwise.
 507:    * @exception SQLException If an error occurs.
 508:    */
 509:   boolean storesMixedCaseQuotedIdentifiers() throws SQLException;
 510: 
 511:   /**
 512:    * This metohd returns the quote string for SQL identifiers.
 513:    *
 514:    * @return The quote string for SQL identifers, or a space if quoting
 515:    *         is not supported.
 516:    * @exception SQLException If an error occurs.
 517:    */
 518:   String getIdentifierQuoteString() throws SQLException;
 519: 
 520:   /**
 521:    * This method returns a comma separated list of all the SQL keywords in
 522:    * the database that are not in SQL92.
 523:    *
 524:    * @return The list of SQL keywords not in SQL92.
 525:    * @exception SQLException If an error occurs.
 526:    */
 527:   String getSQLKeywords() throws SQLException;
 528: 
 529:   /**
 530:    * This method returns a comma separated list of math functions.
 531:    *
 532:    * @return The list of math functions.
 533:    * @exception SQLException If an error occurs.
 534:    */
 535:   String getNumericFunctions() throws SQLException;
 536: 
 537:   /**
 538:    * This method returns a comma separated list of string functions.
 539:    *
 540:    * @return The list of string functions.
 541:    * @exception SQLException If an error occurs.
 542:    */
 543:   String getStringFunctions() throws SQLException;
 544: 
 545:   /**
 546:    * This method returns a comma separated list of of system functions.
 547:    *
 548:    * @return A comma separated list of system functions.
 549:    * @exception SQLException If an error occurs.
 550:    */
 551:   String getSystemFunctions() throws SQLException;
 552: 
 553:   /**
 554:    * This method returns comma separated list of time/date functions.
 555:    * 
 556:    * @return The list of time/date functions.
 557:    * @exception SQLException If an error occurs.
 558:    */
 559:   String getTimeDateFunctions() throws SQLException;
 560: 
 561:   /**
 562:    * This method returns the string used to escape wildcards in search strings.
 563:    *
 564:    * @return The string used to escape wildcards in search strings.
 565:    * @exception SQLException If an error occurs.
 566:    */
 567:   String getSearchStringEscape() throws SQLException;
 568: 
 569:   /**
 570:    * This methods returns non-standard characters that can appear in 
 571:    * unquoted identifiers.
 572:    *
 573:    * @return Non-standard characters that can appear in unquoted identifiers.
 574:    * @exception SQLException If an error occurs.
 575:    */
 576:   String getExtraNameCharacters() throws SQLException;
 577: 
 578:   /**
 579:    * This method tests whether or not the database supports
 580:    * "ALTER TABLE ADD COLUMN"
 581:    *
 582:    * @return <code>true</code> if column add supported, <code>false</code>
 583:    *         otherwise.
 584:    * @exception SQLException If an error occurs.
 585:    */
 586:   boolean supportsAlterTableWithAddColumn() throws SQLException;
 587: 
 588:   /**
 589:    * This method tests whether or not the database supports
 590:    * "ALTER TABLE DROP COLUMN"
 591:    *
 592:    * @return <code>true</code> if column drop supported, <code>false</code>
 593:    *         otherwise.
 594:    * @exception SQLException If an error occurs.
 595:    */
 596:   boolean supportsAlterTableWithDropColumn() throws SQLException;
 597: 
 598:   /**
 599:    * This method tests whether or not column aliasing is supported.
 600:    *
 601:    * @return <code>true</code> if column aliasing is supported,
 602:    *         <code>false</code> otherwise.
 603:    * @exception SQLException If an error occurs.
 604:    */
 605:   boolean supportsColumnAliasing() throws SQLException;
 606: 
 607:   /**
 608:    * This method tests whether the concatenation of a NULL and non-NULL
 609:    * value results in a NULL.  This will always be true in fully JDBC compliant
 610:    * drivers.
 611:    *
 612:    * @return <code>true</code> if concatenating NULL and a non-NULL value
 613:    *         returns a NULL, <code>false</code> otherwise.
 614:    * @exception SQLException If an error occurs.
 615:    */
 616:   boolean nullPlusNonNullIsNull() throws SQLException;
 617: 
 618:   /**
 619:    * Tests whether or not CONVERT is supported.
 620:    *
 621:    * @return <code>true</code> if CONVERT is supported, <code>false</code>
 622:    *         otherwise.
 623:    * @exception SQLException If an error occurs.
 624:    */
 625:   boolean supportsConvert() throws SQLException;
 626: 
 627:   /**
 628:    * This method tests whether or not CONVERT can be performed between the
 629:    * specified types.  The types are contants from <code>Types</code>.
 630:    *
 631:    * @param fromType The SQL type to convert from.
 632:    * @param toType The SQL type to convert to.
 633:    * @return <code>true</code> if the conversion can be performed,
 634:    *         <code>false</code> otherwise.
 635:    * @see Types
 636:    */
 637:   boolean supportsConvert(int fromType, int toType) throws
 638:       SQLException;
 639: 
 640:   /**
 641:    * This method tests whether or not table correlation names are 
 642:    * supported.  This will be always be <code>true</code> in a fully JDBC
 643:    * compliant driver.
 644:    *
 645:    * @return <code>true</code> if table correlation names are supported,
 646:    *         <code>false</code> otherwise.
 647:    * @exception SQLException If an error occurs.
 648:    */
 649:   boolean supportsTableCorrelationNames() throws SQLException;
 650: 
 651:   /**
 652:    * This method tests whether correlation names must be different from the
 653:    * name of the table.
 654:    *
 655:    * @return <code>true</code> if the correlation name must be different from
 656:    *         the table name, <code>false</code> otherwise.
 657:    * @exception SQLException If an error occurs.
 658:    */
 659:   boolean supportsDifferentTableCorrelationNames() throws SQLException;
 660: 
 661:   /**
 662:    * This method tests whether or not expressions are allowed in an
 663:    * ORDER BY lists.
 664:    *
 665:    * @return <code>true</code> if expressions are allowed in ORDER BY
 666:    *         lists, <code>false</code> otherwise.
 667:    * @exception SQLException If an error occurs.
 668:    */
 669:   boolean supportsExpressionsInOrderBy() throws SQLException;
 670: 
 671:   /**
 672:    * This method tests whether or ORDER BY on a non-selected column is
 673:    * allowed.
 674:    *
 675:    * @return <code>true</code> if a non-selected column can be used in an
 676:    *         ORDER BY, <code>false</code> otherwise.
 677:    * @exception SQLException If an error occurs.
 678:    */
 679:   boolean supportsOrderByUnrelated() throws SQLException;
 680: 
 681:   /**
 682:    * This method tests whether or not GROUP BY is supported.
 683:    *
 684:    * @return <code>true</code> if GROUP BY is supported, <code>false</code>
 685:    *         otherwise.
 686:    * @exception SQLException If an error occurs.
 687:    */
 688:   boolean supportsGroupBy() throws SQLException;
 689: 
 690:   /**
 691:    * This method tests whether GROUP BY on a non-selected column is
 692:    * allowed.
 693:    *
 694:    * @return <code>true</code> if a non-selected column can be used in a
 695:    *         GROUP BY, <code>false</code> otherwise.
 696:    * @exception SQLException If an error occurs.
 697:    */
 698:   boolean supportsGroupByUnrelated() throws SQLException;
 699: 
 700:   /**
 701:    * This method tests whether or not a GROUP BY can add columns not in the
 702:    * select if it includes all the columns in the select.
 703:    *
 704:    * @return <code>true</code> if GROUP BY an add columns provided it includes
 705:    *         all columns in the select, <code>false</code> otherwise.
 706:    * @exception SQLException If an error occurs.
 707:    */
 708:   boolean supportsGroupByBeyondSelect() throws SQLException;
 709: 
 710:   /**
 711:    * This method tests whether or not the escape character is supported in
 712:    * LIKE expressions.  A fully JDBC compliant driver will always return
 713:    * <code>true</code>.
 714:    *
 715:    * @return <code>true</code> if escapes are supported in LIKE expressions,
 716:    *         <code>false</code> otherwise.
 717:    * @exception SQLException If an error occurs.
 718:    */
 719:   boolean supportsLikeEscapeClause() throws SQLException;
 720: 
 721:   /**
 722:    * This method tests whether multiple result sets for a single statement are
 723:    * supported.
 724:    *
 725:    * @return <code>true</code> if multiple result sets are supported for a 
 726:    *         single statement, <code>false</code> otherwise.
 727:    * @exception SQLException If an error occurs.
 728:    */
 729:   boolean supportsMultipleResultSets() throws SQLException;
 730: 
 731:   /**
 732:    * This method test whether or not multiple transactions may be open
 733:    * at once, as long as they are on different connections.
 734:    *
 735:    * @return <code>true</code> if multiple transactions on different
 736:    *         connections are supported, <code>false</code> otherwise.
 737:    * @exception SQLException If an error occurs.
 738:    */
 739:   boolean supportsMultipleTransactions() throws SQLException;
 740: 
 741:   /**
 742:    * This method tests whether or not columns can be defined as NOT NULL.  A
 743:    * fully JDBC compliant driver always returns <code>true</code>.
 744:    *
 745:    * @return <code>true</code> if NOT NULL columns are supported,
 746:    *         <code>false</code> otherwise.
 747:    * @exception SQLException If an error occurs.
 748:    */
 749:   boolean supportsNonNullableColumns() throws SQLException;
 750: 
 751:   /**
 752:    * This method tests whether or not the minimum grammer for ODBC is supported.
 753:    * A fully JDBC compliant driver will always return <code>true</code>.
 754:    *
 755:    * @return <code>true</code> if the ODBC minimum grammar is supported,
 756:    *         <code>false</code> otherwise.
 757:    * @exception SQLException If an error occurs.
 758:    */
 759:   boolean supportsMinimumSQLGrammar() throws SQLException;
 760: 
 761:   /**
 762:    * This method tests whether or not the core grammer for ODBC is supported.
 763:    *
 764:    * @return <code>true</code> if the ODBC core grammar is supported,
 765:    *         <code>false</code> otherwise.
 766:    * @exception SQLException If an error occurs.
 767:    */
 768:   boolean supportsCoreSQLGrammar() throws SQLException;
 769: 
 770:   /**
 771:    * This method tests whether or not the extended grammer for ODBC is supported.
 772:    *
 773:    * @return <code>true</code> if the ODBC extended grammar is supported,
 774:    *         <code>false</code> otherwise.
 775:    * @exception SQLException If an error occurs.
 776:    */
 777:   boolean supportsExtendedSQLGrammar() throws SQLException;
 778: 
 779:   /**
 780:    * This method tests whether or not the ANSI92 entry level SQL
 781:    * grammar is supported.  A fully JDBC compliant drivers must return
 782:    * <code>true</code>.
 783:    *
 784:    * @return <code>true</code> if the ANSI92 entry level SQL grammar is
 785:    *         supported, <code>false</code> otherwise.
 786:    * @exception SQLException If an error occurs.
 787:    */
 788:   boolean supportsANSI92EntryLevelSQL() throws SQLException;
 789: 
 790:   /**
 791:    * This method tests whether or not the ANSI92 intermediate SQL
 792:    * grammar is supported.  
 793:    *
 794:    * @return <code>true</code> if the ANSI92 intermediate SQL grammar is
 795:    *         supported, <code>false</code> otherwise.
 796:    * @exception SQLException If an error occurs.
 797:    */
 798:   boolean supportsANSI92IntermediateSQL() throws SQLException;
 799: 
 800:   /**
 801:    * This method tests whether or not the ANSI92 full SQL
 802:    * grammar is supported.  
 803:    *
 804:    * @return <code>true</code> if the ANSI92 full SQL grammar is
 805:    *         supported, <code>false</code> otherwise.
 806:    * @exception SQLException If an error occurs.
 807:    */
 808:   boolean supportsANSI92FullSQL() throws SQLException;
 809: 
 810:   /**
 811:    * This method tests whether or not the SQL integrity enhancement
 812:    * facility is supported.
 813:    *
 814:    * @return <code>true</code> if the integrity enhancement facility is
 815:    *         supported, <code>false</code> otherwise.
 816:    * @exception SQLException If an error occurs.
 817:    */
 818:   boolean supportsIntegrityEnhancementFacility() throws SQLException;
 819: 
 820:   /**
 821:    * This method tests whether or not the database supports outer joins.
 822:    *
 823:    * @return <code>true</code> if outer joins are supported, <code>false</code>
 824:    *         otherwise.
 825:    * @exception SQLException If an error occurs.
 826:    */
 827:   boolean supportsOuterJoins() throws SQLException;
 828: 
 829:   /**
 830:    * This method tests whether or not the database supports full outer joins.
 831:    *
 832:    * @return <code>true</code> if full outer joins are supported, 
 833:    *         <code>false</code> otherwise.
 834:    * @exception SQLException If an error occurs.
 835:    */
 836:   boolean supportsFullOuterJoins() throws SQLException;
 837: 
 838:   /**
 839:    * This method tests whether or not the database supports limited outer joins.
 840:    *
 841:    * @return <code>true</code> if limited outer joins are supported, 
 842:    *         <code>false</code> otherwise.
 843:    * @exception SQLException If an error occurs.
 844:    */
 845:   boolean supportsLimitedOuterJoins() throws SQLException;
 846: 
 847:   /**
 848:    * This method returns the vendor's term for "schema".
 849:    *
 850:    * @return The vendor's term for schema.
 851:    * @exception SQLException if an error occurs.
 852:    */
 853:   String getSchemaTerm() throws SQLException;
 854: 
 855:   /**
 856:    * This method returns the vendor's term for "procedure".
 857:    *
 858:    * @return The vendor's term for procedure.
 859:    * @exception SQLException if an error occurs.
 860:    */
 861:   String getProcedureTerm() throws SQLException;
 862: 
 863:   /**
 864:    * This method returns the vendor's term for "catalog".
 865:    *
 866:    * @return The vendor's term for catalog.
 867:    * @exception SQLException if an error occurs.
 868:    */
 869:   String getCatalogTerm() throws SQLException;
 870: 
 871:   /**
 872:    * This method tests whether a catalog name appears at the beginning of
 873:    * a fully qualified table name.
 874:    *
 875:    * @return <code>true</code> if the catalog name appears at the beginning,
 876:    *         <code>false</code> if it appears at the end.
 877:    * @exception SQLException If an error occurs.
 878:    */
 879:   boolean isCatalogAtStart() throws SQLException;
 880: 
 881:   /**
 882:    * This method returns the separator between the catalog name and the
 883:    * table name.
 884:    *
 885:    * @return The separator between the catalog name and the table name.
 886:    * @exception SQLException If an error occurs.
 887:    */
 888:   String getCatalogSeparator() throws SQLException;
 889: 
 890:   /**
 891:    * This method tests whether a catalog name can appear in a data
 892:    * manipulation statement.
 893:    *
 894:    * @return <code>true</code> if a catalog name can appear in a data
 895:    *         manipulation statement, <code>false</code> otherwise.
 896:    * @exception SQLException If an error occurs.
 897:    */
 898:   boolean supportsSchemasInDataManipulation() throws SQLException;
 899: 
 900:   /**
 901:    * This method tests whether a catalog name can appear in a procedure
 902:    * call
 903:    *
 904:    * @return <code>true</code> if a catalog name can appear in a procedure
 905:    *         call, <code>false</code> otherwise.
 906:    * @exception SQLException If an error occurs.
 907:    */
 908:   boolean supportsSchemasInProcedureCalls() throws SQLException;
 909: 
 910:   /**
 911:    * This method tests whether a catalog name can appear in a table definition.
 912:    *
 913:    * @return <code>true</code> if a catalog name can appear in a table
 914:    *         definition, <code>false</code> otherwise.
 915:    * @exception SQLException If an error occurs.
 916:    */
 917:   boolean supportsSchemasInTableDefinitions() throws SQLException;
 918: 
 919:   /**
 920:    * This method tests whether a catalog name can appear in an index definition.
 921:    *
 922:    * @return <code>true</code> if a catalog name can appear in an index
 923:    *         definition, <code>false</code> otherwise.
 924:    * @exception SQLException If an error occurs.
 925:    */
 926:   boolean supportsSchemasInIndexDefinitions() throws SQLException;
 927: 
 928:   /**
 929:    * This method tests whether a catalog name can appear in privilege definitions.
 930:    *
 931:    * @return <code>true</code> if a catalog name can appear in privilege
 932:    *         definition, <code>false</code> otherwise.
 933:    * @exception SQLException If an error occurs.
 934:    */
 935:   boolean supportsSchemasInPrivilegeDefinitions() throws SQLException;
 936: 
 937:   /**
 938:    * This method tests whether a catalog name can appear in a data
 939:    * manipulation statement.
 940:    *
 941:    * @return <code>true</code> if a catalog name can appear in a data
 942:    *         manipulation statement, <code>false</code> otherwise.
 943:    * @exception SQLException If an error occurs.
 944:    */
 945:   boolean supportsCatalogsInDataManipulation() throws SQLException;
 946: 
 947:   /**
 948:    * This method tests whether a catalog name can appear in a procedure
 949:    * call
 950:    *
 951:    * @return <code>true</code> if a catalog name can appear in a procedure
 952:    *         call, <code>false</code> otherwise.
 953:    * @exception SQLException If an error occurs.
 954:    */
 955:   boolean supportsCatalogsInProcedureCalls() throws SQLException;
 956: 
 957:   /**
 958:    * This method tests whether a catalog name can appear in a table definition.
 959:    *
 960:    * @return <code>true</code> if a catalog name can appear in a table
 961:    *         definition, <code>false</code> otherwise.
 962:    * @exception SQLException If an error occurs.
 963:    */
 964:   boolean supportsCatalogsInTableDefinitions() throws SQLException;
 965: 
 966:   /**
 967:    * This method tests whether a catalog name can appear in an index definition.
 968:    *
 969:    * @return <code>true</code> if a catalog name can appear in an index
 970:    *         definition, <code>false</code> otherwise.
 971:    * @exception SQLException If an error occurs.
 972:    */
 973:   boolean supportsCatalogsInIndexDefinitions() throws SQLException;
 974: 
 975:   /**
 976:    * This method tests whether a catalog name can appear in privilege definitions.
 977:    *
 978:    * @return <code>true</code> if a catalog name can appear in privilege
 979:    *         definition, <code>false</code> otherwise.
 980:    * @exception SQLException If an error occurs.
 981:    */
 982:   boolean supportsCatalogsInPrivilegeDefinitions() throws SQLException;
 983: 
 984:   /**
 985:    * This method tests whether or not that database supports positioned
 986:    * deletes.
 987:    *
 988:    * @return <code>true</code> if positioned deletes are supported,
 989:    *         <code>false</code> otherwise.
 990:    * @exception SQLException If an error occurs.
 991:    */
 992:   boolean supportsPositionedDelete() throws SQLException;
 993: 
 994:   /**
 995:    * This method tests whether or not that database supports positioned
 996:    * updates.
 997:    *
 998:    * @return <code>true</code> if positioned updates are supported,
 999:    *         <code>false</code> otherwise.
1000:    * @exception SQLException If an error occurs.
1001:    */
1002:   boolean supportsPositionedUpdate() throws SQLException;
1003: 
1004:   /**
1005:    * This method tests whether or not SELECT FOR UPDATE is supported by the
1006:    * database.
1007:    *
1008:    * @return <code>true</code> if SELECT FOR UPDATE is supported 
1009:    *         <code>false</code> otherwise.
1010:    * @exception SQLException If an error occurs.
1011:    */
1012:   boolean supportsSelectForUpdate() throws SQLException;
1013: 
1014:   /**
1015:    * This method tests whether or not stored procedures are supported on
1016:    * this database.
1017:    *
1018:    * @return <code>true</code> if stored procedures are supported,
1019:    *         <code>false</code> otherwise.
1020:    * @exception SQLException If an error occurs.