Subject Re: JDBC connection and multiple schemas
Author rrokytskyy
> I've just started playing with Firebird 1.5, and already run into
> something I cannot comprehend. It appears to me that in Firebird a
> JDBC connection is associated with schema, which is made part of the
> URL (actually, the URL requires the name of the physical file, but
> since there is a one-to-one correspondence between schema and file,
> one can say that the association is done at the schema level).

There is no schemas in Firebird. There's no one-to-one relation
between schema and file because there is no schema. A file is a
complete database, but there is no schema in the database, i.e. any
logged in user sees unqualified database objects.

> If this is so, how can one run a SELECT against tables that belong
> to different schemas? Normally, one would qualify the table names
> with their schemas, but in Firebird a given connection will know
> only its own schema, so would this even be possible?

Again, there is no schemas. :) And there is no possibility to issue
queries over over multiple databases.

> Any clues, as well as pointers to a good on-line info will be
> appreciated. (I looked at the docs available from Sourceforge, but
> the issue of qualified table names is ignored there. A sign of
> feature not supported?)

Correct, schemas are not supported.

> PS: I tried DatabaseMetaData.getSchemas() method, but the returned
> ResultSet is empty. Another proof that there is no such thing as
> "schema" in Firebird?

Right. See DatabaseMetaData.supportsSchemasXXXX() methods.

Best regards,
Roman Rokytskyy