public class Db2MetadataHandler extends DefaultMetadataHandler
DefaultMetadataHandler
fails with a RuntimeException.| Constructor and Description |
|---|
Db2MetadataHandler() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
matches(ResultSet columnsResultSet,
String catalog,
String schema,
String table,
String column,
boolean caseSensitive)
This method is overridden since - at least with DB2 driver db2jcc-9.5.jar - there is a
problem that the
DatabaseMetaData does not return the same values for catalog and schema
like the columns ResultSet does. |
getColumns, getPrimaryKeys, getSchema, getTables, matches, tableExistspublic boolean matches(ResultSet columnsResultSet, String catalog, String schema, String table, String column, boolean caseSensitive) throws SQLException
DatabaseMetaData does not return the same values for catalog and schema
like the columns ResultSet does. The debugging constellation is as follows
catalog="BLA", catalogName=This problem is taken into account by this metadata handler. Checks if the givenschema="BLA", schemaName="BLA"
resultSet matches the given schema and table name.
The comparison is case sensitive.matches in interface IMetadataHandlermatches in class DefaultMetadataHandlercolumnsResultSet - A result set produced via DatabaseMetaData.getColumns(String, String, String, String)catalog - The name of the catalog to check. If null it is ignored in the comparisonschema - The name of the schema to check. If null it is ignored in the comparisontable - The name of the table to check. If null it is ignored in the comparisoncolumn - The name of the column to check. If null it is ignored in the comparisoncaseSensitive - Whether or not the comparison should be case sensitivetrue if the column metadata of the given resultSet matches
the given schema and table parameters.SQLExceptionDefaultMetadataHandler.matches(java.sql.ResultSet, java.lang.String, java.lang.String, java.lang.String, java.lang.String, boolean)Copyright © 2002-2017. All Rights Reserved.