KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > rmijdbc > RJDatabaseMetaDataServer


1
2 /**
3  * RmiJdbc client/server JDBC Driver
4  * (C) GIE Dyade (Groupe BULL / INRIA Research Center) 1997
5  *
6  * @version 1.0
7  * @author Pierre-Yves Gibello (pierreyves.gibello@experlog.com)
8  * Additional SSL Support
9  * Douglas Hammond(djhammond@sympatico.ca)
10  */

11
12 package org.objectweb.rmijdbc;
13
14 import java.sql.*;
15
16 import java.rmi.*;
17 import java.rmi.server.UnicastRemoteObject JavaDoc;
18 import java.rmi.server.Unreferenced JavaDoc;
19
20 /**
21  * This class provides information about the database as a whole.
22  *
23  * <P>Many of the methods here return lists of information in ResultSets.
24  * You can use the normal ResultSet methods such as getString and getInt
25  * to retrieve the data from these ResultSets. If a given form of
26  * metadata is not available, these methods should throw a java.rmi.RemoteException.
27  *
28  * <P>Some of these methods take arguments that are String patterns. These
29  * arguments all have names such as fooPattern. Within a pattern String, "%"
30  * means match any substring of 0 or more characters, and "_" means match
31  * any one character. Only metadata entries matching the search pattern
32  * are returned. If a search pattern argument is set to a null ref, it means
33  * that argument's criteria should be dropped from the search.
34  *
35  * <P>A java.rmi.RemoteException will be thrown if a driver does not support a meta
36  * data method. In the case of methods that return a ResultSet,
37  * either a ResultSet (which may be empty) is returned or a
38  * java.rmi.RemoteException is thrown.
39  */

40 public class RJDatabaseMetaDataServer
41 extends UnicastRemoteObject JavaDoc
42 implements RJDatabaseMetaDataInterface, Unreferenced JavaDoc {
43
44   java.sql.DatabaseMetaData JavaDoc jdbcMetadata_;
45
46   public RJDatabaseMetaDataServer(java.sql.DatabaseMetaData JavaDoc d)
47   throws RemoteException, SQLException {
48        super(RJJdbcServer.rmiJdbcListenerPort, RJJdbcServer.rmiClientSocketFactory, RJJdbcServer.rmiServerSocketFactory);
49     jdbcMetadata_ = d;
50   }
51
52   public void unreferenced() { Runtime.getRuntime().gc(); }
53
54   //----------------------------------------------------------------------
55
// First, a variety of minor information about the target database.
56

57     /**
58      * Can all the procedures returned by getProcedures be called by the
59      * current user?
60      *
61      * @return true if so
62      */

63   public boolean allProceduresAreCallable()
64   throws RemoteException, SQLException {
65     return jdbcMetadata_.allProceduresAreCallable();
66   }
67
68     /**
69      * Can all the tables returned by getTable be SELECTed by the
70      * current user?
71      *
72      * @return true if so
73      */

74   public boolean allTablesAreSelectable() throws RemoteException, SQLException {
75     return jdbcMetadata_.allTablesAreSelectable();
76   }
77
78     /**
79      * What's the url for this database?
80      *
81      * @return the url or null if it can't be generated
82      */

83   public String JavaDoc getURL() throws RemoteException, SQLException {
84     return jdbcMetadata_.getURL();
85   }
86
87     /**
88      * What's our user name as known to the database?
89      *
90      * @return our database user name
91      */

92   public String JavaDoc getUserName() throws RemoteException, SQLException {
93     return jdbcMetadata_.getUserName();
94   }
95
96     /**
97      * Is the database in read-only mode?
98      *
99      * @return true if so
100      */

101   public boolean isReadOnly() throws RemoteException, SQLException {
102     return jdbcMetadata_.isReadOnly();
103   }
104
105     /**
106      * Are NULL values sorted high?
107      *
108      * @return true if so
109      */

110   public boolean nullsAreSortedHigh() throws RemoteException, SQLException {
111     return jdbcMetadata_.nullsAreSortedHigh();
112   }
113
114     /**
115      * Are NULL values sorted low?
116      *
117      * @return true if so
118      */

119   public boolean nullsAreSortedLow() throws RemoteException, SQLException {
120     return jdbcMetadata_.nullsAreSortedLow();
121   }
122
123     /**
124      * Are NULL values sorted at the start regardless of sort order?
125      *
126      * @return true if so
127      */

128   public boolean nullsAreSortedAtStart() throws RemoteException, SQLException {
129     return jdbcMetadata_.nullsAreSortedAtStart();
130   }
131
132     /**
133      * Are NULL values sorted at the end regardless of sort order?
134      *
135      * @return true if so
136      */

137   public boolean nullsAreSortedAtEnd() throws RemoteException, SQLException {
138     return jdbcMetadata_.nullsAreSortedAtEnd();
139   }
140
141     /**
142      * What's the name of this database product?
143      *
144      * @return database product name
145      */

146   public String JavaDoc getDatabaseProductName() throws RemoteException, SQLException {
147     return jdbcMetadata_.getDatabaseProductName();
148   }
149
150     /**
151      * What's the version of this database product?
152      *
153      * @return database version
154      */

155   public String JavaDoc getDatabaseProductVersion() throws RemoteException, SQLException {
156     return jdbcMetadata_.getDatabaseProductVersion();
157   }
158
159     /**
160      * What's the name of this JDBC driver?
161      *
162      * @return JDBC driver name
163      */

164   public String JavaDoc getDriverName() throws RemoteException, SQLException {
165     return "RmiJdbc!" + jdbcMetadata_.getDriverName();
166   }
167
168     /**
169      * What's the version of this JDBC driver?
170      *
171      * @return JDBC driver version
172      */

173   public String JavaDoc getDriverVersion() throws RemoteException, SQLException {
174     return jdbcMetadata_.getDriverVersion();
175   }
176
177     /**
178      * What's this JDBC driver's major version number?
179      *
180      * @return JDBC driver major version
181      */

182   public int getDriverMajorVersion() {
183     return jdbcMetadata_.getDriverMajorVersion();
184   }
185
186     /**
187      * What's this JDBC driver's minor version number?
188      *
189      * @return JDBC driver minor version number
190      */

191   public int getDriverMinorVersion() {
192     return jdbcMetadata_.getDriverMinorVersion();
193   }
194
195     /**
196      * Does the database store tables in a local file?
197      *
198      * @return true if so
199      */

200   public boolean usesLocalFiles() throws RemoteException, SQLException {
201     return jdbcMetadata_.usesLocalFiles();
202   }
203
204     /**
205      * Does the database use a file for each table?
206      *
207      * @return true if the database uses a local file for each table
208      */

209   public boolean usesLocalFilePerTable() throws RemoteException, SQLException {
210     return jdbcMetadata_.usesLocalFilePerTable();
211   }
212
213     /**
214      * Does the database treat mixed case unquoted SQL identifiers as
215      * case sensitive and as a result store them in mixed case?
216      *
217      * A JDBC-Compliant driver will always return false.
218      *
219      * @return true if so
220      */

221   public boolean supportsMixedCaseIdentifiers()
222   throws RemoteException, SQLException {
223     return jdbcMetadata_.supportsMixedCaseIdentifiers();
224   }
225
226     /**
227      * Does the database treat mixed case unquoted SQL identifiers as
228      * case insensitive and store them in upper case?
229      *
230      * @return true if so
231      */

232   public boolean storesUpperCaseIdentifiers() throws RemoteException, SQLException {
233     return jdbcMetadata_.storesUpperCaseIdentifiers();
234   }
235
236     /**
237      * Does the database treat mixed case unquoted SQL identifiers as
238      * case insensitive and store them in lower case?
239      *
240      * @return true if so
241      */

242   public boolean storesLowerCaseIdentifiers() throws RemoteException, SQLException {
243     return jdbcMetadata_.storesLowerCaseIdentifiers();
244   }
245
246     /**
247      * Does the database treat mixed case unquoted SQL identifiers as
248      * case insensitive and store them in mixed case?
249      *
250      * @return true if so
251      */

252   public boolean storesMixedCaseIdentifiers() throws RemoteException, SQLException {
253     return jdbcMetadata_.storesMixedCaseIdentifiers();
254   }
255
256     /**
257      * Does the database treat mixed case quoted SQL identifiers as
258      * case sensitive and as a result store them in mixed case?
259      *
260      * A JDBC-Compliant driver will always return false.
261      *
262      * @return true if so
263      */

264   public boolean supportsMixedCaseQuotedIdentifiers()
265   throws RemoteException, SQLException {
266     return jdbcMetadata_.supportsMixedCaseQuotedIdentifiers();
267   }
268
269     /**
270      * Does the database treat mixed case quoted SQL identifiers as
271      * case insensitive and store them in upper case?
272      *
273      * @return true if so
274      */

275   public boolean storesUpperCaseQuotedIdentifiers()
276   throws RemoteException, SQLException {
277     return jdbcMetadata_.storesUpperCaseQuotedIdentifiers();
278   }
279
280     /**
281      * Does the database treat mixed case quoted SQL identifiers as
282      * case insensitive and store them in lower case?
283      *
284      * @return true if so
285      */

286   public boolean storesLowerCaseQuotedIdentifiers()
287   throws RemoteException, SQLException {
288     return jdbcMetadata_.storesLowerCaseQuotedIdentifiers();
289   }
290
291     /**
292      * Does the database treat mixed case quoted SQL identifiers as
293      * case insensitive and store them in mixed case?
294      *
295      * @return true if so
296      */

297   public boolean storesMixedCaseQuotedIdentifiers()
298   throws RemoteException, SQLException {
299     return jdbcMetadata_.storesMixedCaseQuotedIdentifiers();
300   }
301
302     /**
303      * What's the string used to quote SQL identifiers?
304      * This returns a space " " if identifier quoting isn't supported.
305      *
306      * A JDBC-Compliant driver always uses a double quote character.
307      *
308      * @return the quoting string
309      */

310   public String JavaDoc getIdentifierQuoteString() throws RemoteException, SQLException {
311     return jdbcMetadata_.getIdentifierQuoteString();
312   }
313
314     /**
315      * Get a comma separated list of all a database's SQL keywords
316      * that are NOT also SQL92 keywords.
317      *
318      * @return the list
319      */

320   public String JavaDoc getSQLKeywords() throws RemoteException, SQLException {
321     return jdbcMetadata_.getSQLKeywords();
322   }
323
324     /**
325      * Get a comma separated list of math functions.
326      *
327      * @return the list
328      */

329   public String JavaDoc getNumericFunctions() throws RemoteException, SQLException {
330     return jdbcMetadata_.getNumericFunctions();
331   }
332
333     /**
334      * Get a comma separated list of string functions.
335      *
336      * @return the list
337      */

338   public String JavaDoc getStringFunctions() throws RemoteException, SQLException {
339     return jdbcMetadata_.getStringFunctions();
340   }
341
342     /**
343      * Get a comma separated list of system functions.
344      *
345      * @return the list
346      */

347   public String JavaDoc getSystemFunctions() throws RemoteException, SQLException {
348     return jdbcMetadata_.getSystemFunctions();
349   }
350
351     /**
352      * Get a comma separated list of time and date functions.
353      *
354      * @return the list
355      */

356   public String JavaDoc getTimeDateFunctions() throws RemoteException, SQLException {
357     return jdbcMetadata_.getTimeDateFunctions();
358   }
359
360     /**
361      * This is the string that can be used to escape '_' or '%' in
362      * the string pattern style catalog search parameters.
363      *
364      * <P>The '_' character represents any single character.
365      * <P>The '%' character represents any sequence of zero or
366      * more characters.
367      * @return the string used to escape wildcard characters
368      */

369   public String JavaDoc getSearchStringEscape() throws RemoteException, SQLException {
370     return jdbcMetadata_.getSearchStringEscape();
371   }
372
373     /**
374      * Get all the "extra" characters that can be used in unquoted
375      * identifier names (those beyond a-z, A-Z, 0-9 and _).
376      *
377      * @return the string containing the extra characters
378      */

379   public String JavaDoc getExtraNameCharacters() throws RemoteException, SQLException {
380     return jdbcMetadata_.getExtraNameCharacters();
381   }
382
383     //--------------------------------------------------------------------
384
// Functions describing which features are supported.
385

386     /**
387      * Is "ALTER TABLE" with add column supported?
388      *
389      * @return true if so
390      */

391   public boolean supportsAlterTableWithAddColumn()
392   throws RemoteException, SQLException {
393     return jdbcMetadata_.supportsAlterTableWithAddColumn();
394   }
395
396     /**
397      * Is "ALTER TABLE" with drop column supported?
398      *
399      * @return true if so
400      */

401   public boolean supportsAlterTableWithDropColumn()
402   throws RemoteException, SQLException {
403     return jdbcMetadata_.supportsAlterTableWithDropColumn();
404   }
405
406     /**
407      * Is column aliasing supported?
408      *
409      * <P>If so, the SQL AS clause can be used to provide names for
410      * computed columns or to provide alias names for columns as
411      * required.
412      *
413      * A JDBC-Compliant driver always returns true.
414      *
415      * @return true if so
416      */

417   public boolean supportsColumnAliasing() throws RemoteException, SQLException {
418     return jdbcMetadata_.supportsColumnAliasing();
419   }
420
421     /**
422      * Are concatenations between NULL and non-NULL values NULL?
423      *
424      * A JDBC-Compliant driver always returns true.
425      *
426      * @return true if so
427      */

428   public boolean nullPlusNonNullIsNull() throws RemoteException, SQLException {
429     return jdbcMetadata_.nullPlusNonNullIsNull();
430   }
431
432     /**
433      * Is the CONVERT function between SQL types supported?
434      *
435      * @return true if so
436      */

437   public boolean supportsConvert() throws RemoteException, SQLException {
438     return jdbcMetadata_.supportsConvert();
439   }
440
441     /**
442      * Is CONVERT between the given SQL types supported?
443      *
444      * @param fromType the type to convert from
445      * @param toType the type to convert to
446      * @return true if so
447      * @see Types
448      */

449   public boolean supportsConvert(int fromType, int toType)
450   throws RemoteException, SQLException {
451     return jdbcMetadata_.supportsConvert();
452   }
453
454     /**
455      * Are table correlation names supported?
456      *
457      * A JDBC-Compliant driver always returns true.
458      *
459      * @return true if so
460      */

461   public boolean supportsTableCorrelationNames()
462   throws RemoteException, SQLException {
463     return jdbcMetadata_.supportsTableCorrelationNames();
464   }
465
466     /**
467      * If table correlation names are supported, are they restricted
468      * to be different from the names of the tables?
469      *
470      * @return true if so
471      */

472   public boolean supportsDifferentTableCorrelationNames()
473   throws RemoteException, SQLException {
474     return jdbcMetadata_.supportsDifferentTableCorrelationNames();
475   }
476
477     /**
478      * Are expressions in "ORDER BY" lists supported?
479      *
480      * @return true if so
481      */

482   public boolean supportsExpressionsInOrderBy()
483   throws RemoteException, SQLException {
484     return jdbcMetadata_.supportsExpressionsInOrderBy();
485   }
486
487     /**
488      * Can an "ORDER BY" clause use columns not in the SELECT?
489      *
490      * @return true if so
491      */

492   public boolean supportsOrderByUnrelated() throws RemoteException, SQLException {
493     return jdbcMetadata_.supportsOrderByUnrelated();
494   }
495
496     /**
497      * Is some form of "GROUP BY" clause supported?
498      *
499      * @return true if so
500      */

501   public boolean supportsGroupBy() throws RemoteException, SQLException {
502     return jdbcMetadata_.supportsGroupBy();
503   }
504
505     /**
506      * Can a "GROUP BY" clause use columns not in the SELECT?
507      *
508      * @return true if so
509      */

510   public boolean supportsGroupByUnrelated() throws RemoteException, SQLException {
511     return jdbcMetadata_.supportsGroupByUnrelated();
512   }
513
514     /**
515      * Can a "GROUP BY" clause add columns not in the SELECT
516      * provided it specifies all the columns in the SELECT?
517      *
518      * @return true if so
519      */

520   public boolean supportsGroupByBeyondSelect() throws RemoteException, SQLException {
521     return jdbcMetadata_.supportsGroupByBeyondSelect();
522   }
523
524     /**
525      * Is the escape character in "LIKE" clauses supported?
526      *
527      * A JDBC-Compliant driver always returns true.
528      *
529      * @return true if so
530      */

531   public boolean supportsLikeEscapeClause() throws RemoteException, SQLException {
532     return jdbcMetadata_.supportsLikeEscapeClause();
533   }
534
535     /**
536      * Are multiple ResultSets from a single execute supported?
537      *
538      * @return true if so
539      */

540   public boolean supportsMultipleResultSets() throws RemoteException, SQLException {
541     return jdbcMetadata_.supportsMultipleResultSets();
542   }
543
544     /**
545      * Can we have multiple transactions open at once (on different
546      * connections)?
547      *
548      * @return true if so
549      */

550   public boolean supportsMultipleTransactions()
551   throws RemoteException, SQLException {
552     return jdbcMetadata_.supportsMultipleTransactions();
553   }
554
555     /**
556      * Can columns be defined as non-nullable?
557      *
558      * A JDBC-Compliant driver always returns true.
559      *
560      * @return true if so
561      */

562   public boolean supportsNonNullableColumns() throws RemoteException, SQLException {
563     return jdbcMetadata_.supportsNonNullableColumns();
564   }
565
566     /**
567      * Is the ODBC Minimum SQL grammar supported?
568      *
569      * All JDBC-Compliant drivers must return true.
570      *
571      * @return true if so
572      */

573   public boolean supportsMinimumSQLGrammar() throws RemoteException, SQLException {
574     return jdbcMetadata_.supportsMinimumSQLGrammar();
575   }
576
577     /**
578      * Is the ODBC Core SQL grammar supported?
579      *
580      * @return true if so
581      */

582   public boolean supportsCoreSQLGrammar() throws RemoteException, SQLException {
583     return jdbcMetadata_.supportsCoreSQLGrammar();
584   }
585
586     /**
587      * Is the ODBC Extended SQL grammar supported?
588      *
589      * @return true if so
590      */

591   public boolean supportsExtendedSQLGrammar() throws RemoteException, SQLException {
592     return jdbcMetadata_.supportsExtendedSQLGrammar();
593   }
594
595     /**
596      * Is the ANSI92 entry level SQL grammar supported?
597      *
598      * All JDBC-Compliant drivers must return true.
599      *
600      * @return true if so
601      */

602   public boolean supportsANSI92EntryLevelSQL() throws RemoteException, SQLException {
603     return jdbcMetadata_.supportsANSI92EntryLevelSQL();
604   }
605
606     /**
607      * Is the ANSI92 intermediate SQL grammar supported?
608      *
609      * @return true if so
610      */

611   public boolean supportsANSI92IntermediateSQL()
612   throws RemoteException, SQLException {
613     return jdbcMetadata_.supportsANSI92IntermediateSQL();
614   }
615
616     /**
617      * Is the ANSI92 full SQL grammar supported?
618      *
619      * @return true if so
620      */

621   public boolean supportsANSI92FullSQL() throws RemoteException, SQLException {
622     return jdbcMetadata_.supportsANSI92FullSQL();
623   }
624
625     /**
626      * Is the SQL Integrity Enhancement Facility supported?
627      *
628      * @return true if so
629      */

630   public boolean supportsIntegrityEnhancementFacility()
631   throws RemoteException, SQLException {
632     return jdbcMetadata_.supportsIntegrityEnhancementFacility();
633   }
634
635     /**
636      * Is some form of outer join supported?
637      *
638      * @return true if so
639      */

640   public boolean supportsOuterJoins() throws RemoteException, SQLException {
641     return jdbcMetadata_.supportsOuterJoins();
642   }
643
644     /**
645      * Are full nested outer joins supported?
646      *
647      * @return true if so
648      */

649   public boolean supportsFullOuterJoins() throws RemoteException, SQLException {
650     return jdbcMetadata_.supportsFullOuterJoins();
651   }
652
653     /**
654      * Is there limited support for outer joins? (This will be true
655      * if supportFullOuterJoins is true.)
656      *
657      * @return true if so
658      */

659   public boolean supportsLimitedOuterJoins()
660   throws RemoteException, SQLException {
661     return jdbcMetadata_.supportsLimitedOuterJoins();
662   }
663
664     /**
665      * What's the database vendor's preferred term for "schema"?
666      *
667      * @return the vendor term
668      */

669   public String JavaDoc getSchemaTerm() throws RemoteException, SQLException {
670     return jdbcMetadata_.getSchemaTerm();
671   }
672
673     /**
674      * What's the database vendor's preferred term for "procedure"?
675      *
676      * @return the vendor term
677      */

678   public String JavaDoc getProcedureTerm() throws RemoteException, SQLException {
679     return jdbcMetadata_.getProcedureTerm();
680   }
681
682     /**
683      * What's the database vendor's preferred term for "catalog"?
684      *
685      * @return the vendor term
686      */

687   public String JavaDoc getCatalogTerm() throws RemoteException, SQLException {
688     return jdbcMetadata_.getCatalogTerm();
689   }
690
691     /**
692      * Does a catalog appear at the start of a qualified table name?
693      * (Otherwise it appears at the end)
694      *
695      * @return true if it appears at the start
696      */

697   public boolean isCatalogAtStart() throws RemoteException, SQLException {
698     return jdbcMetadata_.isCatalogAtStart();
699   }
700
701     /**
702      * What's the separator between catalog and table name?
703      *
704      * @return the separator string
705      */

706   public String JavaDoc getCatalogSeparator() throws RemoteException, SQLException {
707     return jdbcMetadata_.getCatalogSeparator();
708   }
709
710     /**
711      * Can a schema name be used in a data manipulation statement?
712      *
713      * @return true if so
714      */

715   public boolean supportsSchemasInDataManipulation()
716   throws RemoteException, SQLException {
717     return jdbcMetadata_.supportsSchemasInDataManipulation();
718   }
719
720     /**
721      * Can a schema name be used in a procedure call statement?
722      *
723      * @return true if so
724      */

725   public boolean supportsSchemasInProcedureCalls()
726   throws RemoteException, SQLException {
727     return jdbcMetadata_.supportsSchemasInProcedureCalls();
728   }
729
730     /**
731      * Can a schema name be used in a table definition statement?
732      *
733      * @return true if so
734      */

735   public boolean supportsSchemasInTableDefinitions()
736   throws RemoteException, SQLException {
737     return jdbcMetadata_.supportsSchemasInTableDefinitions();
738   }
739
740     /**
741      * Can a schema name be used in an index definition statement?
742      *
743      * @return true if so
744      */

745   public boolean supportsSchemasInIndexDefinitions()
746   throws RemoteException, SQLException {
747     return jdbcMetadata_.supportsSchemasInIndexDefinitions();
748   }
749
750     /**
751      * Can a schema name be used in a privilege definition statement?
752      *
753      * @return true if so
754      */

755   public boolean supportsSchemasInPrivilegeDefinitions()
756   throws RemoteException, SQLException {
757     return jdbcMetadata_.supportsSchemasInPrivilegeDefinitions();
758   }
759
760     /**
761      * Can a catalog name be used in a data manipulation statement?
762      *
763      * @return true if so
764      */

765   public boolean supportsCatalogsInDataManipulation()
766   throws RemoteException, SQLException {
767     return jdbcMetadata_.supportsCatalogsInDataManipulation();
768   }
769
770     /**
771      * Can a catalog name be used in a procedure call statement?
772      *
773      * @return true if so
774      */

775   public boolean supportsCatalogsInProcedureCalls()
776   throws RemoteException, SQLException {
777     return jdbcMetadata_.supportsCatalogsInProcedureCalls();
778   }
779
780     /**
781      * Can a catalog name be used in a table definition statement?
782      *
783      * @return true if so
784      */

785   public boolean supportsCatalogsInTableDefinitions()
786   throws RemoteException, SQLException {
787     return jdbcMetadata_.supportsCatalogsInTableDefinitions();
788   }
789
790     /**
791      * Can a catalog name be used in an index definition statement?
792      *
793      * @return true if so
794      */

795   public boolean supportsCatalogsInIndexDefinitions()
796   throws RemoteException, SQLException {
797     return jdbcMetadata_.supportsCatalogsInIndexDefinitions();
798   }
799
800     /**
801      * Can a catalog name be used in a privilege definition statement?
802      *
803      * @return true if so
804      */

805   public boolean supportsCatalogsInPrivilegeDefinitions()
806   throws RemoteException, SQLException {
807     return jdbcMetadata_.supportsCatalogsInPrivilegeDefinitions();
808   }
809
810
811     /**
812      * Is positioned DELETE supported?
813      *
814      * @return true if so
815      */

816   public boolean supportsPositionedDelete()
817   throws RemoteException, SQLException {
818     return jdbcMetadata_.supportsPositionedDelete();
819   }
820
821     /**
822      * Is positioned UPDATE supported?
823      *
824      * @return true if so
825      */

826   public boolean supportsPositionedUpdate()
827   throws RemoteException, SQLException {
828     return jdbcMetadata_.supportsPositionedUpdate();
829   }
830
831     /**
832      * Is SELECT for UPDATE supported?
833      *
834      * @return true if so
835      */

836   public boolean supportsSelectForUpdate()
837   throws RemoteException, SQLException {
838     return jdbcMetadata_.supportsSelectForUpdate();
839   }
840
841     /**
842      * Are stored procedure calls using the stored procedure escape
843      * syntax supported?
844      *
845      * @return true if so
846      */

847   public boolean supportsStoredProcedures()
848   throws RemoteException, SQLException {
849     return jdbcMetadata_.supportsStoredProcedures();
850   }
851
852     /**
853      * Are subqueries in comparison expressions supported?
854      *
855      * A JDBC-Compliant driver always returns true.
856      *
857      * @return true if so
858      */

859   public boolean supportsSubqueriesInComparisons()
860   throws RemoteException, SQLException {
861     return jdbcMetadata_.supportsSubqueriesInComparisons();
862   }
863
864     /**
865      * Are subqueries in 'exists' expressions supported?
866      *
867      * A JDBC-Compliant driver always returns true.
868      *
869      * @return true if so
870      */

871   public boolean supportsSubqueriesInExists()
872   throws RemoteException, SQLException {
873     return jdbcMetadata_.supportsSubqueriesInExists();
874   }
875
876     /**
877      * Are subqueries in 'in' statements supported?
878      *
879      * A JDBC-Compliant driver always returns true.
880      *
881      * @return true if so
882      */

883   public boolean supportsSubqueriesInIns()
884   throws RemoteException, SQLException {
885     return jdbcMetadata_.supportsSubqueriesInIns();
886   }
887
888     /**
889      * Are subqueries in quantified expressions supported?
890      *
891      * A JDBC-Compliant driver always returns true.
892      *
893      * @return true if so
894      */

895   public boolean supportsSubqueriesInQuantifieds()
896   throws RemoteException, SQLException {
897     return jdbcMetadata_.supportsSubqueriesInQuantifieds();
898   }
899
900     /**
901      * Are correlated subqueries supported?
902      *
903      * A JDBC-Compliant driver always returns true.
904      *
905      * @return true if so
906      */

907   public boolean supportsCorrelatedSubqueries()
908   throws RemoteException, SQLException {
909     return jdbcMetadata_.supportsCorrelatedSubqueries();
910   }
911
912     /**
913      * Is SQL UNION supported?
914      *
915      * @return true if so
916      */

917   public boolean supportsUnion() throws RemoteException, SQLException {
918     return jdbcMetadata_.supportsUnion();
919   }
920
921     /**
922      * Is SQL UNION ALL supported?
923      *
924      * @return true if so
925      */

926   public boolean supportsUnionAll() throws RemoteException, SQLException {
927     return jdbcMetadata_.supportsUnionAll();
928   }
929
930     /**
931      * Can cursors remain open across commits?
932      *
933      * @return true if cursors always remain open;
934      * false if they might not remain open
935      */

936   public boolean supportsOpenCursorsAcrossCommit()
937   throws RemoteException, SQLException {
938     return jdbcMetadata_.supportsOpenCursorsAcrossCommit();
939   }
940
941     /**
942      * Can cursors remain open across rollbacks?
943      *
944      * @return true if cursors always remain open;
945      * false if they might not remain open
946      */

947   public boolean supportsOpenCursorsAcrossRollback()
948   throws RemoteException, SQLException {
949     return jdbcMetadata_.supportsOpenCursorsAcrossRollback();
950   }
951
952     /**
953      * Can statements remain open across commits?
954      *
955      * @return true if statements always remain open;
956      * false if they might not remain open
957      */

958   public boolean supportsOpenStatementsAcrossCommit()
959   throws RemoteException, SQLException {
960     return jdbcMetadata_.supportsOpenStatementsAcrossCommit();
961   }
962
963     /**
964      * Can statements remain open across rollbacks?
965      *
966      * @return true if statements always remain open;
967      * false if they might not remain open
968      */

969   public boolean supportsOpenStatementsAcrossRollback()
970   throws RemoteException, SQLException {
971     return jdbcMetadata_.supportsOpenStatementsAcrossRollback();
972   }
973
974     //----------------------------------------------------------------------
975
// The following group of methods exposes various limitations
976
// based on the target database with the current driver.
977
// Unless otherwise specified, a result of zero means there is no
978
// limit, or the limit is not known.
979

980     /**
981      * How many hex characters can you have in an inline binary literal?
982      *
983      * @return max literal length
984      */

985   public int getMaxBinaryLiteralLength() throws RemoteException, SQLException {
986     return jdbcMetadata_.getMaxBinaryLiteralLength();
987   }
988
989     /**
990      * What's the max length for a character literal?
991      *
992      * @return max literal length
993      */

994   public int getMaxCharLiteralLength() throws RemoteException, SQLException {
995     return jdbcMetadata_.getMaxCharLiteralLength();
996   }
997
998     /**
999      * What's the limit on column name length?
1000     *
1001     * @return max literal length
1002     */

1003  public int getMaxColumnNameLength() throws RemoteException, SQLException {
1004    return jdbcMetadata_.getMaxColumnNameLength();
1005  }
1006
1007    /**
1008     * What's the maximum number of columns in a "GROUP BY" clause?
1009     *
1010     * @return max number of columns
1011     */

1012  public int getMaxColumnsInGroupBy() throws RemoteException, SQLException {
1013    return jdbcMetadata_.getMaxColumnsInGroupBy();
1014  }
1015
1016    /**
1017     * What's the maximum number of columns allowed in an index?
1018     *
1019     * @return max columns
1020     */

1021  public int getMaxColumnsInIndex() throws RemoteException, SQLException {
1022    return jdbcMetadata_.getMaxColumnsInIndex();
1023  }
1024
1025    /**
1026     * What's the maximum number of columns in an "ORDER BY" clause?
1027     *
1028     * @return max columns
1029     */

1030  public int getMaxColumnsInOrderBy() throws RemoteException, SQLException {
1031    return jdbcMetadata_.getMaxColumnsInOrderBy();
1032  }
1033
1034    /**
1035     * What's the maximum number of columns in a "SELECT" list?
1036     *
1037     * @return max columns
1038     */

1039  public int getMaxColumnsInSelect() throws RemoteException, SQLException {
1040    return jdbcMetadata_.getMaxColumnsInSelect();
1041  }
1042
1043    /**
1044     * What's the maximum number of columns in a table?
1045     *
1046     * @return max columns
1047     */

1048  public int getMaxColumnsInTable() throws RemoteException, SQLException {
1049    return jdbcMetadata_.getMaxColumnsInTable();
1050  }
1051
1052    /**
1053     * How many active connections can we have at a time to this database?
1054     *
1055     * @return max connections
1056     */

1057  public int getMaxConnections() throws RemoteException, SQLException {
1058    return jdbcMetadata_.getMaxConnections();
1059  }
1060
1061    /**
1062     * What's the maximum cursor name length?
1063     *
1064     * @return max cursor name length in bytes
1065     */

1066  public int getMaxCursorNameLength() throws RemoteException, SQLException {
1067    return jdbcMetadata_.getMaxCursorNameLength();
1068  }
1069
1070    /**
1071     * What's the maximum length of an index (in bytes)?
1072     *
1073     * @return max index length in bytes
1074     */

1075  public int getMaxIndexLength() throws RemoteException, SQLException {
1076    return jdbcMetadata_.getMaxIndexLength();
1077  }
1078
1079    /**
1080     * What's the maximum length allowed for a schema name?
1081     *
1082     * @return max name length in bytes
1083     */

1084  public int getMaxSchemaNameLength() throws RemoteException, SQLException {
1085    return jdbcMetadata_.getMaxSchemaNameLength();
1086  }
1087
1088    /**
1089     * What's the maximum length of a procedure name?
1090     *
1091     * @return max name length in bytes
1092     */

1093  public int getMaxProcedureNameLength() throws RemoteException, SQLException {
1094    return jdbcMetadata_.getMaxProcedureNameLength();
1095  }
1096
1097    /**
1098     * What's the maximum length of a catalog name?
1099     *
1100     * @return max name length in bytes
1101     */

1102  public int getMaxCatalogNameLength() throws RemoteException, SQLException {
1103    return jdbcMetadata_.getMaxCatalogNameLength();
1104  }
1105
1106    /**
1107     * What's the maximum length of a single row?
1108     *
1109     * @return max row size in bytes
1110     */

1111  public int getMaxRowSize() throws RemoteException, SQLException {
1112    return jdbcMetadata_.getMaxRowSize();
1113  }
1114
1115    /**
1116     * Did getMaxRowSize() include LONGVARCHAR and LONGVARBINARY
1117     * blobs?
1118     *
1119     * @return true if so
1120     */

1121  public boolean doesMaxRowSizeIncludeBlobs()
1122  throws RemoteException, SQLException {
1123    return jdbcMetadata_.doesMaxRowSizeIncludeBlobs();
1124  }
1125
1126    /**
1127     * What's the maximum length of a SQL statement?
1128     *
1129     * @return max length in bytes
1130     */

1131  public int getMaxStatementLength() throws RemoteException, SQLException {
1132    return jdbcMetadata_.getMaxStatementLength();
1133  }
1134
1135    /**
1136     * How many active statements can we have open at one time to this
1137     * database?
1138     *
1139     * @return the maximum
1140     */

1141  public int getMaxStatements() throws RemoteException, SQLException {
1142    return jdbcMetadata_.getMaxStatements();
1143  }
1144
1145    /**
1146     * What's the maximum length of a table name?
1147     *
1148     * @return max name length in bytes
1149     */

1150  public int getMaxTableNameLength() throws RemoteException, SQLException {
1151    return jdbcMetadata_.getMaxTableNameLength();
1152  }
1153
1154    /**
1155     * What's the maximum number of tables in a SELECT?
1156     *
1157     * @return the maximum
1158     */

1159  public int getMaxTablesInSelect() throws RemoteException, SQLException {
1160    return jdbcMetadata_.getMaxTablesInSelect();
1161  }
1162
1163    /**
1164     * What's the maximum length of a user name?
1165     *
1166     * @return max name length in bytes
1167     */

1168  public int getMaxUserNameLength() throws RemoteException, SQLException {
1169    return jdbcMetadata_.getMaxUserNameLength();
1170  }
1171
1172    //----------------------------------------------------------------------
1173

1174    /**
1175     * What's the database's default transaction isolation level? The
1176     * values are defined in java.sql.Connection.
1177     *
1178     * @return the default isolation level
1179     * @see Connection
1180     */

1181  public int getDefaultTransactionIsolation()
1182  throws RemoteException, SQLException {
1183    return jdbcMetadata_.getDefaultTransactionIsolation();
1184  }
1185
1186    /**
1187     * Are transactions supported? If not, commit is a noop and the
1188     * isolation level is TRANSACTION_NONE.
1189     *
1190     * @return true if transactions are supported
1191     */

1192  public boolean supportsTransactions() throws RemoteException, SQLException {
1193    return jdbcMetadata_.supportsTransactions();
1194  }
1195
1196    /**
1197     * Does the database support the given transaction isolation level?
1198     *
1199     * @param level the values are defined in java.sql.Connection
1200     * @return true if so
1201     * @see Connection
1202     */

1203  public boolean supportsTransactionIsolationLevel(int level)
1204  throws RemoteException, SQLException {
1205    return jdbcMetadata_.supportsTransactionIsolationLevel(level);
1206  }
1207
1208    /**
1209     * Are both data definition and data manipulation statements
1210     * within a transaction supported?
1211     *
1212     * @return true if so
1213     */

1214  public boolean supportsDataDefinitionAndDataManipulationTransactions()
1215  throws RemoteException, SQLException {
1216   return jdbcMetadata_.supportsDataDefinitionAndDataManipulationTransactions();
1217  }
1218
1219    /**
1220     * Are only data manipulation statements within a transaction
1221     * supported?
1222     *
1223     * @return true if so
1224     */

1225  public boolean supportsDataManipulationTransactionsOnly()
1226  throws RemoteException, SQLException {
1227    return jdbcMetadata_.supportsDataManipulationTransactionsOnly();
1228  }
1229
1230    /**
1231     * Does a data definition statement within a transaction force the
1232     * transaction to commit?
1233     *
1234     * @return true if so
1235     */

1236  public boolean dataDefinitionCausesTransactionCommit()
1237  throws RemoteException, SQLException {
1238    return jdbcMetadata_.dataDefinitionCausesTransactionCommit();
1239  }
1240
1241    /**
1242     * Is a data definition statement within a transaction ignored?
1243     *
1244     * @return true if so
1245     */

1246  public boolean dataDefinitionIgnoredInTransactions()
1247  throws RemoteException, SQLException {
1248    return jdbcMetadata_.dataDefinitionIgnoredInTransactions();
1249  }
1250
1251
1252    /**
1253     * Get a description of stored procedures available in a
1254     * catalog.
1255     *
1256     * <P>Only procedure descriptions matching the schema and
1257     * procedure name criteria are returned. They are ordered by
1258     * PROCEDURE_SCHEM, and PROCEDURE_NAME.
1259     *
1260     * <P>Each procedure description has the the following columns:
1261     * <OL>
1262     * <LI><B>PROCEDURE_CAT</B> String => procedure catalog (may be null)
1263     * <LI><B>PROCEDURE_SCHEM</B> String => procedure schema (may be null)
1264     * <LI><B>PROCEDURE_NAME</B> String => procedure name
1265     * <LI> reserved for future use
1266     * <LI> reserved for future use
1267     * <LI> reserved for future use
1268     * <LI><B>REMARKS</B> String => explanatory comment on the procedure
1269     * <LI><B>PROCEDURE_TYPE</B> short => kind of procedure:
1270     * <UL>
1271     * <LI> procedureResultUnknown - May return a result
1272     * <LI> procedureNoResult - Does not return a result
1273     * <LI> procedureReturnsResult - Returns a result
1274     * </UL>
1275     * </OL>
1276     *
1277     * @param catalog a catalog name; "" retrieves those without a
1278     * catalog; null means drop catalog name from the selection criteria
1279     * @param schemaPattern a schema name pattern; "" retrieves those
1280     * without a schema
1281     * @param procedureNamePattern a procedure name pattern
1282     * @return ResultSet - each row is a procedure description
1283     * @see #getSearchStringEscape
1284     */

1285  public RJResultSetInterface getProcedures(String JavaDoc catalog,
1286  String JavaDoc schemaPattern, String JavaDoc procedureNamePattern)
1287  throws RemoteException, SQLException {
1288    return new RJResultSetServer(jdbcMetadata_.getProcedures(catalog,
1289     schemaPattern, procedureNamePattern));
1290  }
1291
1292    /**
1293     * Get a description of a catalog's stored procedure parameters
1294     * and result columns.
1295     *
1296     * <P>Only descriptions matching the schema, procedure and
1297     * parameter name criteria are returned. They are ordered by
1298     * PROCEDURE_SCHEM and PROCEDURE_NAME. Within this, the return value,
1299     * if any, is first. Next are the parameter descriptions in call
1300     * order. The column descriptions follow in column number order.
1301     *
1302     * <P>Each row in the ResultSet is a parameter description or
1303     * column description with the following fields:
1304     * <OL>
1305     * <LI><B>PROCEDURE_CAT</B> String => procedure catalog (may be null)
1306     * <LI><B>PROCEDURE_SCHEM</B> String => procedure schema (may be null)
1307     * <LI><B>PROCEDURE_NAME</B> String => procedure name
1308     * <LI><B>COLUMN_NAME</B> String => column/parameter name
1309     * <LI><B>COLUMN_TYPE</B> Short => kind of column/parameter:
1310     * <UL>
1311     * <LI> procedureColumnUnknown - nobody knows
1312     * <LI> procedureColumnIn - IN parameter
1313     * <LI> procedureColumnInOut - INOUT parameter
1314     * <LI> procedureColumnOut - OUT parameter
1315     * <LI> procedureColumnReturn - procedure return value
1316     * <LI> procedureColumnResult - result column in ResultSet
1317     * </UL>
1318     * <LI><B>DATA_TYPE</B> short => SQL type from java.sql.Types
1319     * <LI><B>TYPE_NAME</B> String => SQL type name
1320     * <LI><B>PRECISION</B> int => precision
1321     * <LI><B>LENGTH</B> int => length in bytes of data
1322     * <LI><B>SCALE</B> short => scale
1323     * <LI><B>RADIX</B> short => radix
1324     * <LI><B>NULLABLE</B> short => can it contain NULL?
1325     * <UL>
1326     * <LI> procedureNoNulls - does not allow NULL values
1327     * <LI> procedureNullable - allows NULL values
1328     * <LI> procedureNullableUnknown - nullability unknown
1329     * </UL>
1330     * <LI><B>REMARKS</B> String => comment describing parameter/column
1331     * </OL>
1332     *
1333     * <P><B>Note:</B> Some databases may not return the column
1334     * descriptions for a procedure. Additional columns beyond
1335     * REMARKS can be defined by the database.
1336     *
1337     * @param catalog a catalog name; "" retrieves those without a
1338     * catalog; null means drop catalog name from the selection criteria
1339     * @param schemaPattern a schema name pattern; "" retrieves those
1340     * without a schema
1341     * @param procedureNamePattern a procedure name pattern
1342     * @param columnNamePattern a column name pattern
1343     * @return ResultSet - each row is a stored procedure parameter or
1344     * column description
1345     * @see #getSearchStringEscape
1346     */

1347  public RJResultSetInterface getProcedureColumns(String JavaDoc catalog,
1348  String JavaDoc schemaPattern, String JavaDoc procedureNamePattern,
1349  String JavaDoc columnNamePattern) throws RemoteException, SQLException {
1350    return new RJResultSetServer(jdbcMetadata_.getProcedureColumns(catalog,
1351      schemaPattern, procedureNamePattern, columnNamePattern));
1352  }
1353
1354    /**
1355     * Get a description of tables available in a catalog.
1356     *
1357     * <P>Only table descriptions matching the catalog, schema, table
1358     * name and type criteria are returned. They are ordered by
1359     * TABLE_TYPE, TABLE_SCHEM and TABLE_NAME.
1360     *
1361     * <P>Each table description has the following columns:
1362     * <OL>
1363     * <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1364     * <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1365     * <LI><B>TABLE_NAME</B> String => table name
1366     * <LI><B>TABLE_TYPE</B> String => table type. Typical types are "TABLE",
1367     * "VIEW", "SYSTEM TABLE", "GLOBAL TEMPORARY",
1368     * "LOCAL TEMPORARY", "ALIAS", "SYNONYM".
1369     * <LI><B>REMARKS</B> String => explanatory comment on the table
1370     * </OL>
1371     *
1372     * <P><B>Note:</B> Some databases may not return information for
1373     * all tables.
1374     *
1375     * @param catalog a catalog name; "" retrieves those without a
1376     * catalog; null means drop catalog name from the selection criteria
1377     * @param schemaPattern a schema name pattern; "" retrieves those
1378     * without a schema
1379     * @param tableNamePattern a table name pattern
1380     * @param types a list of table types to include; null returns all types
1381     * @return ResultSet - each row is a table description
1382     * @see #getSearchStringEscape
1383     */

1384  public RJResultSetInterface getTables(String JavaDoc catalog, String JavaDoc schemaPattern,
1385  String JavaDoc tableNamePattern, String JavaDoc types[])
1386  throws RemoteException, SQLException {
1387    return new RJResultSetServer(jdbcMetadata_.getTables(catalog,
1388     schemaPattern, tableNamePattern, types));
1389  }
1390
1391    /**
1392     * Get the schema names available in this database. The results
1393     * are ordered by schema name.
1394     *
1395     * <P>The schema column is:
1396     * <OL>
1397     * <LI><B>TABLE_SCHEM</B> String => schema name
1398     * </OL>
1399     *
1400     * @return ResultSet - each row has a single String column that is a
1401     * schema name
1402     */

1403  public RJResultSetInterface getSchemas()
1404  throws RemoteException, SQLException {
1405    return new RJResultSetServer(jdbcMetadata_.getSchemas());
1406  }
1407
1408    /**
1409     * Get the catalog names available in this database. The results
1410     * are ordered by catalog name.
1411     *
1412     * <P>The catalog column is:
1413     * <OL>
1414     * <LI><B>TABLE_CAT</B> String => catalog name
1415     * </OL>
1416     *
1417     * @return ResultSet - each row has a single String column that is a
1418     * catalog name
1419     */

1420  public RJResultSetInterface getCatalogs()
1421  throws RemoteException, SQLException {
1422    return new RJResultSetServer(jdbcMetadata_.getCatalogs());
1423  }
1424
1425    /**
1426     * Get the table types available in this database. The results
1427     * are ordered by table type.
1428     *
1429     * <P>The table type is:
1430     * <OL>
1431     * <LI><B>TABLE_TYPE</B> String => table type. Typical types are "TABLE",
1432     * "VIEW", "SYSTEM TABLE", "GLOBAL TEMPORARY",
1433     * "LOCAL TEMPORARY", "ALIAS", "SYNONYM".
1434     * </OL>
1435     *
1436     * @return ResultSet - each row has a single String column that is a
1437     * table type
1438     */

1439  public RJResultSetInterface getTableTypes()
1440  throws RemoteException, SQLException {
1441    return new RJResultSetServer(jdbcMetadata_.getTableTypes());
1442  }
1443
1444    /**
1445     * Get a description of table columns available in a catalog.
1446     *
1447     * <P>Only column descriptions matching the catalog, schema, table
1448     * and column name criteria are returned. They are ordered by
1449     * TABLE_SCHEM, TABLE_NAME and ORDINAL_POSITION.
1450     *
1451     * <P>Each column description has the following columns:
1452     * <OL>
1453     * <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1454     * <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1455     * <LI><B>TABLE_NAME</B> String => table name
1456     * <LI><B>COLUMN_NAME</B> String => column name
1457     * <LI><B>DATA_TYPE</B> short => SQL type from java.sql.Types
1458     * <LI><B>TYPE_NAME</B> String => Data source dependent type name
1459     * <LI><B>COLUMN_SIZE</B> int => column size. For char or date
1460     * types this is the maximum number of characters, for numeric or
1461     * decimal types this is precision.
1462     * <LI><B>BUFFER_LENGTH</B> is not used.
1463     * <LI><B>DECIMAL_DIGITS</B> int => the number of fractional digits
1464     * <LI><B>NUM_PREC_RADIX</B> int => Radix (typically either 10 or 2)
1465     * <LI><B>NULLABLE</B> int => is NULL allowed?
1466     * <UL>
1467     * <LI> columnNoNulls - might not allow NULL values
1468     * <LI> columnNullable - definitely allows NULL values
1469     * <LI> columnNullableUnknown - nullability unknown
1470     * </UL>
1471     * <LI><B>REMARKS</B> String => comment describing column (may be null)
1472     * <LI><B>COLUMN_DEF</B> String => default value (may be null)
1473     * <LI><B>SQL_DATA_TYPE</B> int => unused
1474     * <LI><B>SQL_DATETIME_SUB</B> int => unused
1475     * <LI><B>CHAR_OCTET_LENGTH</B> int => for char types the
1476     * maximum number of bytes in the column
1477     * <LI><B>ORDINAL_POSITION</B> int => index of column in table
1478     * (starting at 1)
1479     * <LI><B>IS_NULLABLE</B> String => "NO" means column definitely
1480     * does not allow NULL values; "YES" means the column might
1481     * allow NULL values. An empty string means nobody knows.
1482     * </OL>
1483     *
1484     * @param catalog a catalog name; "" retrieves those without a
1485     * catalog; null means drop catalog name from the selection criteria
1486     * @param schemaPattern a schema name pattern; "" retrieves those
1487     * without a schema
1488     * @param tableNamePattern a table name pattern
1489     * @param columnNamePattern a column name pattern
1490     * @return ResultSet - each row is a column description
1491     * @see #getSearchStringEscape
1492     */

1493  public RJResultSetInterface getColumns(String JavaDoc catalog, String JavaDoc schemaPattern,
1494  String JavaDoc tableNamePattern, String JavaDoc columnNamePattern)
1495  throws RemoteException, SQLException {
1496    return new RJResultSetServer(jdbcMetadata_.getColumns(catalog,
1497     schemaPattern, tableNamePattern, columnNamePattern));
1498  }
1499
1500    /**
1501     * Get a description of the access rights for a table's columns.
1502     *
1503     * <P>Only privileges matching the column name criteria are
1504     * returned. They are ordered by COLUMN_NAME and PRIVILEGE.
1505     *
1506     * <P>Each privilige description has the following columns:
1507     * <OL>
1508     * <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1509     * <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1510     * <LI><B>TABLE_NAME</B> String => table name
1511     * <LI><B>COLUMN_NAME</B> String => column name
1512     * <LI><B>GRANTOR</B> => grantor of access (may be null)
1513     * <LI><B>GRANTEE</B> String => grantee of access
1514     * <LI><B>PRIVILEGE</B> String => name of access (SELECT,
1515     * INSERT, UPDATE, REFRENCES, ...)
1516     * <LI><B>IS_GRANTABLE</B> String => "YES" if grantee is permitted
1517     * to grant to others; "NO" if not; null if unknown
1518     * </OL>
1519     *
1520     * @param catalog a catalog name; "" retrieves those without a
1521     * catalog; null means drop catalog name from the selection criteria
1522     * @param schema a schema name; "" retrieves those without a schema
1523     * @param table a table name
1524     * @param columnNamePattern a column name pattern
1525     * @return ResultSet - each row is a column privilege description
1526     * @see #getSearchStringEscape
1527     */

1528  public RJResultSetInterface getColumnPrivileges(String JavaDoc catalog, String JavaDoc schema,
1529  String JavaDoc table, String JavaDoc columnNamePattern) throws RemoteException, SQLException {
1530    return new RJResultSetServer(jdbcMetadata_.getColumnPrivileges(catalog,
1531     schema, table, columnNamePattern));
1532  }
1533
1534    /**
1535     * Get a description of the access rights for each table available
1536     * in a catalog. Note that a table privilege applies to one or
1537     * more columns in the table. It would be wrong to assume that
1538     * this priviledge applies to all columns (this may be true for
1539     * some systems but is not true for all.)
1540     *
1541     * <P>Only privileges matching the schema and table name
1542     * criteria are returned. They are ordered by TABLE_SCHEM,
1543     * TABLE_NAME, and PRIVILEGE.
1544     *
1545     * <P>Each privilige description has the following columns:
1546     * <OL>
1547     * <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1548     * <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1549     * <LI><B>TABLE_NAME</B> String => table name
1550     * <LI><B>GRANTOR</B> => grantor of access (may be null)
1551     * <LI><B>GRANTEE</B> String => grantee of access
1552     * <LI><B>PRIVILEGE</B> String => name of access (SELECT,
1553     * INSERT, UPDATE, REFRENCES, ...)
1554     * <LI><B>IS_GRANTABLE</B> String => "YES" if grantee is permitted
1555     * to grant to others; "NO" if not; null if unknown
1556     * </OL>
1557     *
1558     * @param catalog a catalog name; "" retrieves those without a
1559     * catalog; null means drop catalog name from the selection criteria
1560     * @param schemaPattern a schema name pattern; "" retrieves those
1561     * without a schema
1562     * @param tableNamePattern a table name pattern
1563     * @return ResultSet - each row is a table privilege description
1564     * @see #getSearchStringEscape
1565     */

1566  public RJResultSetInterface getTablePrivileges(String JavaDoc catalog,
1567  String JavaDoc schemaPattern, String JavaDoc tableNamePattern)
1568  throws RemoteException, SQLException {
1569    return new RJResultSetServer(jdbcMetadata_.getTablePrivileges(catalog,
1570     schemaPattern, tableNamePattern));
1571  }
1572
1573    /**
1574     * Get a description of a table's optimal set of columns that
1575     * uniquely identifies a row. They are ordered by SCOPE.
1576     *
1577     * <P>Each column description has the following columns:
1578     * <OL>
1579     * <LI><B>SCOPE</B> short => actual scope of result
1580     * <UL>
1581     * <LI> bestRowTemporary - very temporary, while using row
1582     * <LI> bestRowTransaction - valid for remainder of current transaction
1583     * <LI> bestRowSession - valid for remainder of current session
1584     * </UL>
1585     * <LI><B>COLUMN_NAME</B> String => column name
1586     * <LI><B>DATA_TYPE</B> short => SQL data type from java.sql.Types
1587     * <LI><B>TYPE_NAME</B> String => Data source dependent type name
1588     * <LI><B>COLUMN_SIZE</B> int => precision
1589     * <LI><B>BUFFER_LENGTH</B> int => not used
1590     * <LI><B>DECIMAL_DIGITS</B> short => scale
1591     * <LI><B>PSEUDO_COLUMN</B> short => is this a pseudo column
1592     * like an Oracle ROWID
1593     * <UL>
1594     * <LI> bestRowUnknown - may or may not be pseudo column
1595     * <LI> bestRowNotPseudo - is NOT a pseudo column
1596     * <LI> bestRowPseudo - is a pseudo column
1597     * </UL>
1598     * </OL>
1599     *
1600     * @param catalog a catalog name; "" retrieves those without a
1601     * catalog; null means drop catalog name from the selection criteria
1602     * @param schema a schema name; "" retrieves those without a schema
1603     * @param table a table name
1604     * @param scope the scope of interest; use same values as SCOPE
1605     * @param nullable include columns that are nullable?
1606     * @return ResultSet - each row is a column description
1607     */

1608  public RJResultSetInterface getBestRowIdentifier(String JavaDoc catalog,
1609  String JavaDoc schema, String JavaDoc table, int scope, boolean nullable)
1610  throws RemoteException, SQLException {
1611    return new RJResultSetServer(jdbcMetadata_.getBestRowIdentifier(catalog,
1612     schema, table, scope, nullable));
1613  }
1614  
1615    /**
1616     * Get a description of a table's columns that are automatically
1617     * updated when any value in a row is updated. They are
1618     * unordered.
1619     *
1620     * <P>Each column description has the following columns:
1621     * <OL>
1622     * <LI><B>SCOPE</B> short => is not used
1623     * <LI><B>COLUMN_NAME</B> String => column name
1624     * <LI><B>DATA_TYPE</B> short => SQL data type from java.sql.Types
1625     * <LI><B>TYPE_NAME</B> String => Data source dependent type name
1626     * <LI><B>COLUMN_SIZE</B> int => precision
1627     * <LI><B>BUFFER_LENGTH</B> int => length of column value in bytes
1628     * <LI><B>DECIMAL_DIGITS</B> short => scale
1629     * <LI><B>PSEUDO_COLUMN</B> short => is this a pseudo column
1630     * like an Oracle ROWID
1631     * <UL>
1632     * <LI> versionColumnUnknown - may or may not be pseudo column
1633     * <LI> versionColumnNotPseudo - is NOT a pseudo column
1634     * <LI> versionColumnPseudo - is a pseudo column
1635     * </UL>
1636     * </OL>
1637     *
1638     * @param catalog a catalog name; "" retrieves those without a
1639     * catalog; null means drop catalog name from the selection criteria
1640     * @param schema a schema name; "" retrieves those without a schema
1641     * @param table a table name
1642     * @return ResultSet - each row is a column description
1643     */

1644  public RJResultSetInterface getVersionColumns(String JavaDoc catalog, String JavaDoc schema,
1645  String JavaDoc table) throws RemoteException, SQLException {
1646    return new RJResultSetServer(jdbcMetadata_.getVersionColumns(catalog,
1647     schema, table));
1648  }
1649  
1650    /**
1651     * Get a description of a table's primary key columns. They
1652     * are ordered by COLUMN_NAME.
1653     *
1654     * <P>Each primary key column description has the following columns:
1655     * <OL>
1656     * <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1657     * <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1658     * <LI><B>TABLE_NAME</B> String => table name
1659     * <LI><B>COLUMN_NAME</B> String => column name
1660     * <LI><B>KEY_SEQ</B> short => sequence number within primary key
1661     * <LI><B>PK_NAME</B> String => primary key name (may be null)
1662     * </OL>
1663     *
1664     * @param catalog a catalog name; "" retrieves those without a
1665     * catalog; null means drop catalog name from the selection criteria
1666     * @param schema a schema name pattern; "" retrieves those
1667     * without a schema
1668     * @param table a table name
1669     * @return ResultSet - each row is a primary key column description
1670     */

1671  public RJResultSetInterface getPrimaryKeys(String JavaDoc catalog, String JavaDoc schema,
1672  String JavaDoc table) throws RemoteException, SQLException {
1673    return new RJResultSetServer(jdbcMetadata_.getPrimaryKeys(catalog,
1674     schema, table));
1675  }
1676
1677    /**
1678     * Get a description of the primary key columns that are
1679     * referenced by a table's foreign key columns (the primary keys
1680     * imported by a table). They are ordered by PKTABLE_CAT,
1681     * PKTABLE_SCHEM, PKTABLE_NAME, and KEY_SEQ.
1682     *
1683     * <P>Each primary key column description has the following columns:
1684     * <OL>
1685     * <LI><B>PKTABLE_CAT</B> String => primary key table catalog
1686     * being imported (may be null)
1687     * <LI><B>PKTABLE_SCHEM</B> String => primary key table schema
1688     * being imported (may be null)
1689     * <LI><B>PKTABLE_NAME</B> String => primary key table name
1690     * being imported
1691     * <LI><B>PKCOLUMN_NAME</B> String => primary key column name
1692     * being imported
1693     * <LI><B>FKTABLE_CAT</B> String => foreign key table catalog (may be null)
1694     * <LI><B>FKTABLE_SCHEM</B> String => foreign key table schema (may be null)
1695     * <LI><B>FKTABLE_NAME</B> String => foreign key table name
1696     * <LI><B>FKCOLUMN_NAME</B> String => foreign key column name
1697     * <LI><B>KEY_SEQ</B> short => sequence number within foreign key
1698     * <LI><B>UPDATE_RULE</B> short => What happens to
1699     * foreign key when primary is updated:
1700     * <UL>
1701     * <LI> importedNoAction - do not allow update of primary
1702     * key if it has been imported
1703     * <LI> importedKeyCascade - change imported key to agree
1704     * with primary key update
1705     * <LI> importedKeySetNull - change imported key to NULL if
1706     * its primary key has been updated
1707     * <LI> importedKeySetDefault - change imported key to default values
1708     * if its primary key has been updated
1709     * <LI> importedKeyRestrict - same as importedKeyNoAction
1710     * (for ODBC 2.x compatibility)
1711     * </UL>
1712     * <LI><B>DELETE_RULE</B> short => What happens to
1713     * the foreign key when primary is deleted.
1714     * <UL>
1715     * <LI> importedKeyNoAction - do not allow delete of primary
1716     * key if it has been imported
1717     * <LI> importedKeyCascade - delete rows that import a deleted key
1718     * <LI> importedKeySetNull - change imported key to NULL if
1719     * its primary key has been deleted
1720     * <LI> importedKeyRestrict - same as importedKeyNoAction
1721     * (for ODBC 2.x compatibility)
1722     * <LI> importedKeySetDefault - change imported key to default if
1723     * its primary key has been deleted
1724     * </UL>
1725     * <LI><B>FK_NAME</B> String => foreign key name (may be null)
1726     * <LI><B>PK_NAME</B> String => primary key name (may be null)
1727     * <LI><B>DEFERRABILITY</B> short => can the evaluation of foreign key
1728     * constraints be deferred until commit
1729     * <UL>
1730     * <LI> importedKeyInitiallyDeferred - see SQL92 for definition
1731     * <LI> importedKeyInitiallyImmediate - see SQL92 for definition
1732     * <LI> importedKeyNotDeferrable - see SQL92 for definition
1733     * </UL>
1734     * </OL>
1735     *
1736     * @param catalog a catalog name; "" retrieves those without a
1737     * catalog; null means drop catalog name from the selection criteria
1738     * @param schema a schema name pattern; "" retrieves those
1739     * without a schema
1740     * @param table a table name
1741     * @return ResultSet - each row is a primary key column description
1742     * @see #getExportedKeys
1743     */

1744  public RJResultSetInterface getImportedKeys(String JavaDoc catalog, String JavaDoc schema,
1745  String JavaDoc table) throws RemoteException, SQLException {
1746    return new RJResultSetServer(jdbcMetadata_.getImportedKeys(catalog,
1747     schema, table));
1748  }
1749
1750    /**
1751     * Get a description of the foreign key columns that reference a
1752     * table's primary key columns (the foreign keys exported by a
1753     * table). They are ordered by FKTABLE_CAT, FKTABLE_SCHEM,
1754     * FKTABLE_NAME, and KEY_SEQ.
1755     *
1756     * <P>Each foreign key column description has the following columns:
1757     * <OL>
1758     * <LI><B>PKTABLE_CAT</B> String => primary key table catalog (may be null)
1759     * <LI><B>PKTABLE_SCHEM</B> String => primary key table schema (may be null)
1760     * <LI><B>PKTABLE_NAME</B> String => primary key table name
1761     * <LI><B>PKCOLUMN_NAME</B> String => primary key column name
1762     * <LI><B>FKTABLE_CAT</B> String => foreign key table catalog (may be null)
1763     * being exported (may be null)
1764     * <LI><B>FKTABLE_SCHEM</B> String => foreign key table schema (may be null)
1765     * being exported (may be null)
1766     * <LI><B>FKTABLE_NAME</B> String => foreign key table name
1767     * being exported
1768     * <LI><B>FKCOLUMN_NAME</B> String => foreign key column name
1769     * being exported
1770     * <LI><B>KEY_SEQ</B> short => sequence number within foreign key
1771     * <LI><B>UPDATE_RULE</B> short => What happens to
1772     * foreign key when primary is updated:
1773     * <UL>
1774     * <LI> importedNoAction - do not allow update of primary
1775     * key if it has been imported
1776     * <LI> importedKeyCascade - change imported key to agree
1777     * with primary key update
1778     * <LI> importedKeySetNull - change imported key to NULL if
1779     * its primary key has been updated
1780     * <LI> importedKeySetDefault - change imported key to default values
1781     * if its primary key has been updated
1782     * <LI> importedKeyRestrict - same as importedKeyNoAction
1783     * (for ODBC 2.x compatibility)
1784     * </UL>
1785     * <LI><B>DELETE_RULE</B> short => What happens to
1786     * the foreign key when primary is deleted.
1787     * <UL>
1788     * <LI> importedKeyNoAction - do not allow delete of primary
1789     * key if it has been imported
1790     * <LI> importedKeyCascade - delete rows that import a deleted key
1791     * <LI> importedKeySetNull - change imported key to NULL if
1792     * its primary key has been deleted
1793     * <LI> importedKeyRestrict - same as importedKeyNoAction
1794     * (for ODBC 2.x compatibility)
1795     * <LI> importedKeySetDefault - change imported key to default if
1796     * its primary key has been deleted
1797     * </UL>
1798     * <LI><B>FK_NAME</B> String => foreign key name (may be null)
1799     * <LI><B>PK_NAME</B> String => primary key name (may be null)
1800     * <LI><B>DEFERRABILITY</B> short => can the evaluation of foreign key
1801     * constraints be deferred until commit
1802     * <UL>
1803     * <LI> importedKeyInitiallyDeferred - see SQL92 for definition
1804     * <LI> importedKeyInitiallyImmediate - see SQL92 for definition
1805     * <LI> importedKeyNotDeferrable - see SQL92 for definition
1806     * </UL>
1807     * </OL>
1808     *
1809     * @param catalog a catalog name; "" retrieves those without a
1810     * catalog; null means drop catalog name from the selection criteria
1811     * @param schema a schema name pattern; "" retrieves those
1812     * without a schema
1813     * @param table a table name
1814     * @return ResultSet - each row is a foreign key column description
1815     * @see #getImportedKeys
1816     */

1817  public RJResultSetInterface getExportedKeys(String JavaDoc catalog, String JavaDoc schema,
1818  String JavaDoc table) throws RemoteException, SQLException {
1819    return new RJResultSetServer(jdbcMetadata_.getExportedKeys(catalog,
1820     schema, table));
1821  }
1822
1823    /**
1824     * Get a description of the foreign key columns in the foreign key
1825     * table that reference the primary key columns of the primary key
1826     * table (describe how one table imports another's key.) This
1827     * should normally return a single foreign key/primary key pair
1828     * (most tables only import a foreign key from a table once.) They
1829     * are ordered by FKTABLE_CAT, FKTABLE_SCHEM, FKTABLE_NAME, and
1830     * KEY_SEQ.
1831     *
1832     * <P>Each foreign key column description has the following columns:
1833     * <OL>
1834     * <LI><B>PKTABLE_CAT</B> String => primary key table catalog (may be null)
1835     * <LI><B>PKTABLE_SCHEM</B> String => primary key table schema (may be null)
1836     * <LI><B>PKTABLE_NAME</B> String => primary key table name
1837     * <LI><B>PKCOLUMN_NAME</B> String => primary key column name
1838     * <LI><B>FKTABLE_CAT</B> String => foreign key table catalog (may be null)
1839     * being exported (may be null)
1840     * <LI><B>FKTABLE_SCHEM</B> String => foreign key table schema (may be null)
1841     * being exported (may be null)
1842     * <LI><B>FKTABLE_NAME</B> String => foreign key table name
1843     * being exported
1844     * <LI><B>FKCOLUMN_NAME</B> String => foreign key column name
1845     * being exported
1846     * <LI><B>KEY_SEQ</B> short => sequence number within foreign key
1847     * <LI><B>UPDATE_RULE</B> short => What happens to
1848     * foreign key when primary is updated:
1849     * <UL>
1850     * <LI> importedNoAction - do not allow update of primary
1851     * key if it has been imported
1852     * <LI> importedKeyCascade - change imported key to agree
1853     * with primary key update
1854     * <LI> importedKeySetNull - change imported key to NULL if
1855     * its primary key has been updated
1856     * <LI> importedKeySetDefault - change imported key to default values
1857     * if its primary key has been updated
1858     * <LI> importedKeyRestrict - same as importedKeyNoAction
1859     * (for ODBC 2.x compatibility)
1860     * </UL>
1861     * <LI><B>DELETE_RULE</B> short => What happens to
1862     * the foreign key when primary is deleted.
1863     * <UL>
1864     * <LI> importedKeyNoAction - do not allow delete of primary
1865     * key if it has been imported
1866     * <LI> importedKeyCascade - delete rows that import a deleted key
1867     * <LI> importedKeySetNull - change imported key to NULL if
1868     * its primary key has been deleted
1869     * <LI> importedKeyRestrict - same as importedKeyNoAction
1870     * (for ODBC 2.x compatibility)
1871     * <LI> importedKeySetDefault - change imported key to default if
1872     * its primary key has been deleted
1873     * </UL>
1874     * <LI><B>FK_NAME</B> String => foreign key name (may be null)
1875     * <LI><B>PK_NAME</B> String => primary key name (may be null)
1876     * <LI><B>DEFERRABILITY</B> short => can the evaluation of foreign key
1877     * constraints be deferred until commit
1878     * <UL>
1879     * <LI> importedKeyInitiallyDeferred - see SQL92 for definition
1880     * <LI> importedKeyInitiallyImmediate - see SQL92 for definition
1881     * <LI> importedKeyNotDeferrable - see SQL92 for definition
1882     * </UL>
1883     * </OL>
1884     *
1885     * @param primaryCatalog a catalog name; "" retrieves those without a
1886     * catalog; null means drop catalog name from the selection criteria
1887     * @param primarySchema a schema name pattern; "" retrieves those
1888     * without a schema
1889     * @param primaryTable the table name that exports the key
1890     * @param foreignCatalog a catalog name; "" retrieves those without a
1891     * catalog; null means drop catalog name from the selection criteria
1892     * @param foreignSchema a schema name pattern; "" retrieves those
1893     * without a schema
1894     * @param foreignTable the table name that imports the key
1895     * @return ResultSet - each row is a foreign key column description
1896     * @see #getImportedKeys
1897     */

1898  public RJResultSetInterface getCrossReference(
1899  String JavaDoc primaryCatalog, String JavaDoc primarySchema, String JavaDoc primaryTable,
1900  String JavaDoc foreignCatalog, String JavaDoc foreignSchema, String JavaDoc foreignTable)
1901  throws RemoteException, SQLException {
1902    return new RJResultSetServer(jdbcMetadata_.getCrossReference(
1903     primaryCatalog, primarySchema, primaryTable,
1904     foreignCatalog, foreignSchema, foreignTable));
1905  }
1906
1907    /**
1908     * Get a description of all the standard SQL types supported by
1909     * this database. They are ordered by DATA_TYPE and then by how
1910     * closely the data type maps to the corresponding JDBC SQL type.
1911     *
1912     * <P>Each type description has the following columns:
1913     * <OL>
1914     * <LI><B>TYPE_NAME</B> String => Type name
1915     * <LI><B>DATA_TYPE</B> short => SQL data type from java.sql.Types
1916     * <LI><B>PRECISION</B> int => maximum precision
1917     * <LI><B>LITERAL_PREFIX</B> String => prefix used to quote a literal
1918     * (may be null)
1919     * <LI><B>LITERAL_SUFFIX</B> String => suffix used to quote a literal
1920            (may be null)
1921     * <LI><B>CREATE_PARAMS</B> String => parameters used in creating
1922     * the type (may be null)
1923     * <LI><B>NULLABLE</B> short => can you use NULL for this type?
1924     * <UL>
1925     * <LI> typeNoNulls - does not allow NULL values
1926     * <LI> typeNullable - allows NULL values
1927     * <LI> typeNullableUnknown - nullability unknown
1928     * </UL>
1929     * <LI><B>CASE_SENSITIVE</B> boolean=> is it case sensitive?
1930     * <LI><B>SEARCHABLE</B> short => can you use "WHERE" based on this type:
1931     * <UL>
1932     * <LI> typePredNone - No support
1933     * <LI> typePredChar - Only supported with WHERE .. LIKE
1934     * <LI> typePredBasic - Supported except for WHERE .. LIKE
1935     * <LI> typeSearchable - Supported for all WHERE ..
1936     * </UL>
1937     * <LI><B>UNSIGNED_ATTRIBUTE</B> boolean => is it unsigned?
1938     * <LI><B>FIXED_PREC_SCALE</B> boolean => can it be a money value?
1939     * <LI><B>AUTO_INCREMENT</B> boolean => can it be used for an
1940     * auto-increment value?
1941     * <LI><B>LOCAL_TYPE_NAME</B> String => localized version of type name
1942     * (may be null)
1943     * <LI><B>MINIMUM_SCALE</B> short => minimum scale supported
1944     * <LI><B>MAXIMUM_SCALE</B> short => maximum scale supported
1945     * <LI><B>SQL_DATA_TYPE</B> int => unused
1946     * <LI><B>SQL_DATETIME_SUB</B> int => unused
1947     * <LI><B>NUM_PREC_RADIX</B> int => usually 2 or 10
1948     * </OL>
1949     *
1950     * @return ResultSet - each row is a SQL type description
1951     */

1952  public RJResultSetInterface getTypeInfo()
1953  throws RemoteException, SQLException {
1954    return new RJResultSetServer(jdbcMetadata_.getTypeInfo());
1955  }
1956  
1957    /**
1958     * Get a description of a table's indices and statistics. They are
1959     * ordered by NON_UNIQUE, TYPE, INDEX_NAME, and ORDINAL_POSITION.
1960     *
1961     * <P>Each index column description has the following columns:
1962     * <OL>
1963     * <LI><B>TABLE_CAT</B> String => table catalog (may be null)
1964     * <LI><B>TABLE_SCHEM</B> String => table schema (may be null)
1965     * <LI><B>TABLE_NAME</B> String => table name
1966     * <LI><B>NON_UNIQUE</B> boolean => Can index values be non-unique?
1967     * false when TYPE is tableIndexStatistic
1968     * <LI><B>INDEX_QUALIFIER</B> String => index catalog (may be null);
1969     * null when TYPE is tableIndexStatistic
1970     * <LI><B>INDEX_NAME</B> String => index name; null when TYPE is
1971     * tableIndexStatistic
1972     * <LI><B>TYPE</B> short => index type:
1973     * <UL>
1974     * <LI> tableIndexStatistic - this identifies table statistics that are
1975     * returned in conjuction with a table's index descriptions
1976     * <LI> tableIndexClustered - this is a clustered index
1977     * <LI> tableIndexHashed - this is a hashed index
1978     * <LI> tableIndexOther - this is some other style of index
1979     * </UL>
1980     * <LI><B>ORDINAL_POSITION</B> short => column sequence number
1981     * within index; zero when TYPE is tableIndexStatistic
1982     * <LI><B>COLUMN_NAME</B> String => column name; null when TYPE is
1983     * tableIndexStatistic
1984     * <LI><B>ASC_OR_DESC</B> String => column sort sequence, "A" => ascending,
1985     * "D" => descending, may be null if sort sequence is not supported;
1986     * null when TYPE is tableIndexStatistic
1987     * <LI><B>CARDINALITY</B> int => When TYPE is tableIndexStatistic, then
1988     * this is the number of rows in the table; otherwise, it is the
1989     * number of unique values in the index.
1990     * <LI><B>PAGES</B> int => When TYPE is tableIndexStatisic then
1991     * this is the number of pages used for the table, otherwise it
1992     * is the number of pages used for the current index.
1993     * <LI><B>FILTER_CONDITION</B> String => Filter condition, if any.
1994     * (may be null)
1995     * </OL>
1996     *
1997     * @param catalog a catalog name; "" retrieves those without a
1998     * catalog; null means drop catalog name from the selection criteria
1999     * @param schema a schema name pattern; "" retrieves those without a schema
2000     * @param table a table name
2001     * @param unique when true, return only indices for unique values;
2002     * when false, return indices regardless of whether unique or not
2003     * @param approximate when true, result is allowed to reflect approximate
2004     * or out of data values; when false, results are requested to be
2005     * accurate
2006     * @return ResultSet - each row is an index column description
2007     */

2008  public RJResultSetInterface getIndexInfo(String JavaDoc catalog, String JavaDoc schema,
2009  String JavaDoc table, boolean unique, boolean approximate)
2010  throws RemoteException, SQLException {
2011    return new RJResultSetServer(jdbcMetadata_.getIndexInfo(catalog,
2012     schema, table, unique, approximate));
2013  }
2014
2015  // JDBC 2. Added Aug 2000, Peter Hearty (peter.hearty@lutris.com).
2016

2017public boolean updatesAreDetected(int type) throws RemoteException, SQLException
2018  {
2019      return jdbcMetadata_.updatesAreDetected(type);
2020  }
2021
2022public boolean supportsResultSetType(int type) throws RemoteException, SQLException
2023  {
2024      return jdbcMetadata_.supportsResultSetType(type);
2025  }
2026
2027public boolean supportsResultSetConcurrency(int type,
2028                                            int concurrency) throws RemoteException, SQLException
2029  {
2030      return jdbcMetadata_.supportsResultSetConcurrency(type,concurrency);
2031  }
2032
2033public boolean ownUpdatesAreVisible(int type) throws RemoteException, SQLException
2034  {
2035      return jdbcMetadata_.ownUpdatesAreVisible(type);
2036  }
2037
2038public boolean ownInsertsAreVisible(int type) throws RemoteException, SQLException
2039  {
2040      return jdbcMetadata_.ownInsertsAreVisible(type);
2041  }
2042
2043public boolean ownDeletesAreVisible(int type) throws RemoteException, SQLException
2044  {
2045      return jdbcMetadata_.ownDeletesAreVisible(type);
2046  }
2047
2048public boolean othersUpdatesAreVisible(int type) throws RemoteException, SQLException
2049  {
2050      return jdbcMetadata_.othersUpdatesAreVisible(type);
2051  }
2052
2053public boolean othersInsertsAreVisible(int type) throws RemoteException, SQLException
2054  {
2055      return jdbcMetadata_.othersInsertsAreVisible(type);
2056  }
2057
2058public boolean othersDeletesAreVisible(int type) throws RemoteException, SQLException
2059  {
2060      return jdbcMetadata_.othersDeletesAreVisible(type);
2061  }
2062
2063public boolean insertsAreDetected(int type) throws RemoteException, SQLException
2064  {
2065      return jdbcMetadata_.insertsAreDetected(type);
2066  }
2067
2068
2069  public RJResultSetInterface getUDTs(String JavaDoc catalog, String JavaDoc schemaPattern,
2070  String JavaDoc typeNamePattern, int[] types) throws RemoteException, SQLException {
2071    return new RJResultSetServer(
2072     jdbcMetadata_.getUDTs(catalog,schemaPattern,typeNamePattern,types));
2073  }
2074
2075
2076public boolean supportsBatchUpdates() throws RemoteException, SQLException
2077  {
2078      return jdbcMetadata_.supportsBatchUpdates();
2079  }
2080
2081public Connection getConnection() throws RemoteException, SQLException
2082  {
2083      return jdbcMetadata_.getConnection();
2084  }
2085
2086public boolean deletesAreDetected(int type) throws RemoteException, SQLException
2087  {
2088      return jdbcMetadata_.deletesAreDetected(type);
2089  }
2090
2091  // ------------------- JDBC 3.0 -------------------------
2092

2093  public boolean supportsSavepoints() throws RemoteException, SQLException {
2094    return jdbcMetadata_.supportsSavepoints();
2095  }
2096
2097  public boolean supportsNamedParameters()
2098  throws RemoteException, SQLException {
2099    return jdbcMetadata_.supportsNamedParameters();
2100  }
2101
2102  public boolean supportsMultipleOpenResults()
2103  throws RemoteException, SQLException {
2104    return jdbcMetadata_.supportsMultipleOpenResults();
2105  }
2106
2107  public boolean supportsGetGeneratedKeys()
2108  throws RemoteException, SQLException {
2109    return jdbcMetadata_.supportsGetGeneratedKeys();
2110  }
2111
2112  public RJResultSetInterface getSuperTypes(String JavaDoc catalog,
2113  String JavaDoc schemaPattern, String JavaDoc typeNamePattern)
2114  throws RemoteException, SQLException {
2115    return new RJResultSetServer(
2116     jdbcMetadata_.getSuperTypes(catalog, schemaPattern, typeNamePattern));
2117  }
2118
2119  public RJResultSetInterface getSuperTables(String JavaDoc catalog,
2120  String JavaDoc schemaPattern, String JavaDoc tableNamePattern)
2121  throws RemoteException, SQLException {
2122    return new RJResultSetServer(
2123     jdbcMetadata_.getSuperTables(catalog, schemaPattern, tableNamePattern));
2124  }
2125
2126  public RJResultSetInterface getAttributes(String JavaDoc catalog,
2127  String JavaDoc schemaPattern, String JavaDoc typeNamePattern, String JavaDoc attributeNamePattern)
2128  throws RemoteException, SQLException {
2129    return new RJResultSetServer(
2130     jdbcMetadata_.getAttributes(catalog, schemaPattern, typeNamePattern,
2131     attributeNamePattern));
2132  }
2133
2134  public boolean supportsResultSetHoldability(int holdability)
2135  throws RemoteException, SQLException {
2136    return jdbcMetadata_.supportsResultSetHoldability(holdability);
2137  }
2138
2139  public int getResultSetHoldability() throws RemoteException, SQLException {
2140    return jdbcMetadata_.getResultSetHoldability();
2141  }
2142
2143  public int getDatabaseMajorVersion() throws RemoteException, SQLException {
2144    return jdbcMetadata_.getDatabaseMajorVersion();
2145  }
2146
2147  public int getDatabaseMinorVersion() throws RemoteException, SQLException {
2148    return jdbcMetadata_.getDatabaseMinorVersion();
2149  }
2150
2151  public int getJDBCMajorVersion() throws RemoteException, SQLException {
2152    return jdbcMetadata_.getJDBCMajorVersion();
2153  }
2154
2155  public int getJDBCMinorVersion() throws RemoteException, SQLException {
2156    return jdbcMetadata_.getJDBCMinorVersion();
2157  }
2158
2159  public int getSQLStateType() throws RemoteException, SQLException {
2160    return jdbcMetadata_.getSQLStateType();
2161  }
2162
2163  public boolean locatorsUpdateCopy() throws RemoteException, SQLException {
2164    return jdbcMetadata_.locatorsUpdateCopy();
2165  }
2166
2167  public boolean supportsStatementPooling()
2168  throws RemoteException, SQLException {
2169    return jdbcMetadata_.supportsStatementPooling();
2170  }
2171
2172};
2173
2174
Popular Tags