Subject Re: [Firebird-Java] Database Introspection with Jaybird
Author Roman Rokytskyy
> I am doing a few database introspections using Jaybird, and I have ran
> into some problems. I am able to extract the metadata without any
> problems, if the tables are created without delimiters. The minute I
> try to introspect a database which has table whose table names and
> column names are delimited with double quotes, then the whole thing
> fails. That is, I am able to get the table names, but I am unable to
> get the columns for that particular table. How do I write some code
> that will allow me to get table names and column names with or without
> delimiters?
> I am using the DatabaseMetadata.getColumns

It's a bug which I missed when preparing 2.0.2

I just checked the history, the issue was fixed for indexes
(DatabaseMetaData.getIndexInfo method), but remains for getColumns. As
workaround, you can check whether the name has lower-case characters and
then quote the table name (prepend and append the double-quote character).

I will, very likely, prepare 2.0.3 this weekend.

> Another question is what sort of pattern shall I use to return only
> the columns for user defined tables?

Pass as types parameter new String[]{"TABLE"}.