Specifying schema name with thin JDBC driver

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Specifying schema name with thin JDBC driver

Valentin Kulichenko
Guys,

Is there a way to specify default schema name when connecting to a cluster
using thin JDBC driver? This seems to be possible with other versions of
JDBC driver, but not with thin one. This forces users to prefix each table
with cache name in all queries, which is not very usable. Do we have any
plans to improve this?

Looks like this user faced this exact problem:
https://stackoverflow.com/questions/46158641/apache-ignite-jdbc-thin-client-does-not-work-with-existing-cache

-Val
Reply | Threaded
Open this post in threaded view
|

Re: Specifying schema name with thin JDBC driver

Vladimir Ozerov
Valya,

Schema name can be specified through Connection.setSchema() method. In the
nearest release it would also be possible to specify schema in connection
string. E.g. "jdbc:ignite:thin://myHost/*mySchema*".

On Mon, Sep 11, 2017 at 10:22 PM, Valentin Kulichenko <
[hidden email]> wrote:

> Guys,
>
> Is there a way to specify default schema name when connecting to a cluster
> using thin JDBC driver? This seems to be possible with other versions of
> JDBC driver, but not with thin one. This forces users to prefix each table
> with cache name in all queries, which is not very usable. Do we have any
> plans to improve this?
>
> Looks like this user faced this exact problem:
> https://stackoverflow.com/questions/46158641/apache-
> ignite-jdbc-thin-client-does-not-work-with-existing-cache
>
> -Val
>
Reply | Threaded
Open this post in threaded view
|

Re: Specifying schema name with thin JDBC driver

dsetrakyan
Vova, I think we need to abandon this "schema-name = table name" legacy. It
is impossible to explain.

Also, I would like to understand the current behavior. When I connect
through JDBC, which schema am I connecting to? How do I know which schemas
are there?

D.

On Wed, Sep 13, 2017 at 1:19 AM, Vladimir Ozerov <[hidden email]>
wrote:

> Valya,
>
> Schema name can be specified through Connection.setSchema() method. In the
> nearest release it would also be possible to specify schema in connection
> string. E.g. "jdbc:ignite:thin://myHost/*mySchema*".
>
> On Mon, Sep 11, 2017 at 10:22 PM, Valentin Kulichenko <
> [hidden email]> wrote:
>
> > Guys,
> >
> > Is there a way to specify default schema name when connecting to a
> cluster
> > using thin JDBC driver? This seems to be possible with other versions of
> > JDBC driver, but not with thin one. This forces users to prefix each
> table
> > with cache name in all queries, which is not very usable. Do we have any
> > plans to improve this?
> >
> > Looks like this user faced this exact problem:
> > https://stackoverflow.com/questions/46158641/apache-
> > ignite-jdbc-thin-client-does-not-work-with-existing-cache
> >
> > -Val
> >
>