How to create tables with JDBC, read with ODBC?

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

How to create tables with JDBC, read with ODBC?

This post was updated on .
Scenario:
64-bit ODBC driver cannot read data created from the Java Thin driver.

Ignite 2.6.
Running a single node server on Centos to test this.

First:
Using Intellij to remotely run the sample code from the Ignite Getting
started page here on SQL:
First Ignite SQL Application
https://apacheignite.readme.io/docs/getting-started

This all works fine.  Tables created, data inserted, data read.  All as
expected.

Next:
Using the ODBC 64-bit driver from Windows 10 to connect to the still running
Ignite server to read the same tables (City, Person).   This does not work.

The ODBC driver appears to be able to get meta data - it gets the table
names from the PUBLIC schema and it understands the fields / field counts in
each table.  However, the ODBC driver is unable to perform any select
operations on the tables. See the following stack trace as an example of the
errors I am seeing:


[13:30:19]   ^-- default [initSize=256.0 MiB, maxSize=6.3 GiB,
persistenceEnabled=false]
[13:33:09,424][SEVERE][client-connector-#45][OdbcRequestHandler] Failed to
execute SQL query [reqId=0, req=OdbcQueryExecuteRequest [schema=PUBLIC,
sqlQry=SELECT COUNT(*) FROM ""PUBLIC"".CITY, timeout=0, args=[]]]
class org.apache.ignite.internal.processors.query.IgniteSQLException: Failed
to parse query. Table  not found; SQL statement:
SELECT COUNT(*) FROM ""PUBLIC"".CITY [42102-195]
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.prepareStatementAndCaches(IgniteH2Indexing.java:2026)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.parseAndSplit(IgniteH2Indexing.java:1796)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:1652)

-----------------------

I have tried various things on the Java side to make the Public schema
explicit, such as this:
conn = DriverManager.getConnection("jdbc:ignite:thin://10.69.11.121/PUBLIC");
// conn.setSchema("PUBLIC");

but this does not help with the ODBC problem.  The Java stuff still works
fine.  Select statements in Java can be written like this and they still
work:

 stmt.executeQuery("SELECT p.name, c.name " +
                                 " FROM PUBLIC.Person p, City c " +
                                 " WHERE p.city_id = c.id"))


Any advice on how this should be done (sample code?) is much appreciated.
Thank you.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
slava.koptilin slava.koptilin
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

Hi,

> I have tried various things on the Java side to make the Public schema explicit, such as this: 
If I'm not mistaken the schema can be specified as a parameter of ODBC connection string.


Thanks,
S.

чт, 6 сент. 2018 г. в 16:59, limabean <[hidden email]>:
Scenario:
64-bit ODBC driver cannot read data created from the Java Thin driver.

Ignite 2.6.
Running a single node server on Centos to test this.

First:
Using Intellij to remotely run the sample code from the Ignite Getting
started page here on SQL:
First Ignite SQL Application
https://apacheignite.readme.io/docs/getting-started

This all works fine.  Tables created, data inserted, data read.  All as
expected.

Next:
Using the ODBC 64-bit driver from Windows 10 to connect to the still running
Ignite server to read the same tables (City, Person).   This does not work.

The ODBC driver appears to be able to get meta data - it gets the table
names from the PUBLIC schema and it understands the fields / field counts in
each table.  However, the ODBC driver is unable to perform any select
operations on the tables. See the following stack trace as an example of the
errors I am seeing:


[13:30:19]   ^-- default [initSize=256.0 MiB, maxSize=6.3 GiB,
persistenceEnabled=false]
[13:33:09,424][SEVERE][client-connector-#45][OdbcRequestHandler] Failed to
execute SQL query [reqId=0, req=OdbcQueryExecuteRequest [schema=PUBLIC,
sqlQry=SELECT COUNT(*) FROM ""PUBLIC"".CITY, timeout=0, args=[]]]
class org.apache.ignite.internal.processors.query.IgniteSQLException: Failed
to parse query. Table  not found; SQL statement:
SELECT COUNT(*) FROM ""PUBLIC"".CITY [42102-195]
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.prepareStatementAndCaches(IgniteH2Indexing.java:2026)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.parseAndSplit(IgniteH2Indexing.java:1796)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:1652)

-----------------------

I have tried various things on the Java side to make the Public schema
explicit, such as this:
conn = DriverManager.getConnection("jdbc:ignite:thin://10.60.1.101/PUBLIC");
// conn.setSchema("PUBLIC");

but this does not help with the ODBC problem.  The Java stuff still works
fine.  Select statements in Java can be written like this and they still
work:

 stmt.executeQuery("SELECT p.name, c.name " +
                                 " FROM PUBLIC.Person p, City c " +
                                 " WHERE p.city_id = c.id"))


Any advice on how this should be done (sample code?) is much appreciated.
Thank you.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
ilya.kasnacheev ilya.kasnacheev
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

In reply to this post by limabean
Hello!

SELECT COUNT(*) FROM ""PUBLIC"".CITY <-- I don't think you need any quotes around PUBLIC.

Regards,
Ilya.
--
Ilya Kasnacheev


чт, 6 сент. 2018 г. в 16:59, limabean <[hidden email]>:
Scenario:
64-bit ODBC driver cannot read data created from the Java Thin driver.

Ignite 2.6.
Running a single node server on Centos to test this.

First:
Using Intellij to remotely run the sample code from the Ignite Getting
started page here on SQL:
First Ignite SQL Application
https://apacheignite.readme.io/docs/getting-started

This all works fine.  Tables created, data inserted, data read.  All as
expected.

Next:
Using the ODBC 64-bit driver from Windows 10 to connect to the still running
Ignite server to read the same tables (City, Person).   This does not work.

The ODBC driver appears to be able to get meta data - it gets the table
names from the PUBLIC schema and it understands the fields / field counts in
each table.  However, the ODBC driver is unable to perform any select
operations on the tables. See the following stack trace as an example of the
errors I am seeing:


[13:30:19]   ^-- default [initSize=256.0 MiB, maxSize=6.3 GiB,
persistenceEnabled=false]
[13:33:09,424][SEVERE][client-connector-#45][OdbcRequestHandler] Failed to
execute SQL query [reqId=0, req=OdbcQueryExecuteRequest [schema=PUBLIC,
sqlQry=SELECT COUNT(*) FROM ""PUBLIC"".CITY, timeout=0, args=[]]]
class org.apache.ignite.internal.processors.query.IgniteSQLException: Failed
to parse query. Table  not found; SQL statement:
SELECT COUNT(*) FROM ""PUBLIC"".CITY [42102-195]
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.prepareStatementAndCaches(IgniteH2Indexing.java:2026)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.parseAndSplit(IgniteH2Indexing.java:1796)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:1652)

-----------------------

I have tried various things on the Java side to make the Public schema
explicit, such as this:
conn = DriverManager.getConnection("jdbc:ignite:thin://10.60.1.101/PUBLIC");
// conn.setSchema("PUBLIC");

but this does not help with the ODBC problem.  The Java stuff still works
fine.  Select statements in Java can be written like this and they still
work:

 stmt.executeQuery("SELECT p.name, c.name " +
                                 " FROM PUBLIC.Person p, City c " +
                                 " WHERE p.city_id = c.id"))


Any advice on how this should be done (sample code?) is much appreciated.
Thank you.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
limabean limabean
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

This post was updated on .
I have no control over the format of the query coming through the ODBC
driver.

That is done automatically as far as I know by the QLIK BI tool that is
leveraging the ODBC driver to try to read data.

Are you suggesting it is QLIK adding the extra quotes that is causing the
problem with the H2 driver
on the Ignite side?

On Thu, Sep 6, 2018 at 11:07 AM Ilya Kasnacheev <ilya.kasnacheev@gmail.com>
wrote:

> Hello!
>
> SELECT COUNT(*) FROM ""PUBLIC"".CITY <-- I don't think you need any quotes
> around PUBLIC.
>
> Regards,
> Ilya.
> --
> Ilya Kasnacheev
>
>
> чт, 6 сент. 2018 г. в 16:59, limabean <drobin1437@gmail.com>:
>
>> Scenario:
>> 64-bit ODBC driver cannot read data created from the Java Thin driver.
>>
>> Ignite 2.6.
>> Running a single node server on Centos to test this.
>>
>> First:
>> Using Intellij to remotely run the sample code from the Ignite Getting
>> started page here on SQL:
>> First Ignite SQL Application
>> https://apacheignite.readme.io/docs/getting-started
>>
>> This all works fine.  Tables created, data inserted, data read.  All as
>> expected.
>>
>> Next:
>> Using the ODBC 64-bit driver from Windows 10 to connect to the still
>> running
>> Ignite server to read the same tables (City, Person).   This does not
>> work.
>>
>> The ODBC driver appears to be able to get meta data - it gets the table
>> names from the PUBLIC schema and it understands the fields / field counts
>> in
>> each table.  However, the ODBC driver is unable to perform any select
>> operations on the tables. See the following stack trace as an example of
>> the
>> errors I am seeing:
>>
>>
>> [13:30:19]   ^-- default [initSize=256.0 MiB, maxSize=6.3 GiB,
>> persistenceEnabled=false]
>> [13:33:09,424][SEVERE][client-connector-#45][OdbcRequestHandler] Failed to
>> execute SQL query [reqId=0, req=OdbcQueryExecuteRequest [schema=PUBLIC,
>> sqlQry=SELECT COUNT(*) FROM ""PUBLIC"".CITY, timeout=0, args=[]]]
>> class org.apache.ignite.internal.processors.query.IgniteSQLException:
>> Failed
>> to parse query. Table  not found; SQL statement:
>> SELECT COUNT(*) FROM ""PUBLIC"".CITY [42102-195]
>>         at
>> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.prepareStatementAndCaches(IgniteH2Indexing.java:2026)
>>
>>         at
>> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.parseAndSplit(IgniteH2Indexing.java:1796)
>>
>>         at
>> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:1652)
>>
>>
>> -----------------------
>>
>> I have tried various things on the Java side to make the Public schema
>> explicit, such as this:
>> conn = DriverManager.getConnection("jdbc:ignite:thin://10.60.1.101/PUBLIC");
>>
>> // conn.setSchema("PUBLIC");
>>
>> but this does not help with the ODBC problem.  The Java stuff still works
>> fine.  Select statements in Java can be written like this and they still
>> work:
>>
>>  stmt.executeQuery("SELECT p.name, c.name " +
>>                                  " FROM PUBLIC.Person p, City c " +
>>                                  " WHERE p.city_id = c.id"))
>>
>>
>> Any advice on how this should be done (sample code?) is much appreciated.
>> Thank you.
>>
>>
>>
>> --
>> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>>
>
ilya.kasnacheev ilya.kasnacheev
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

Hello!

Please try using public (lower case) as schema, since quotes force case sensitivity.

Regards,
--
Ilya Kasnacheev


чт, 6 сент. 2018 г. в 18:25, David Robinson <[hidden email]>:
I have no control over the format of the query coming through the ODBC driver.

That is done automatically as far as I know by the[QLIK BI tool that is leveraging the ODBC driver
to try to read data.

Are you suggesting it is QLIK adding the extra quotes that is causing the problem with the H2 driver
on the Ignite side?

On Thu, Sep 6, 2018 at 11:07 AM Ilya Kasnacheev <[hidden email]> wrote:
Hello!

SELECT COUNT(*) FROM ""PUBLIC"".CITY <-- I don't think you need any quotes around PUBLIC.

Regards,
Ilya.
--
Ilya Kasnacheev


чт, 6 сент. 2018 г. в 16:59, limabean <[hidden email]>:
Scenario:
64-bit ODBC driver cannot read data created from the Java Thin driver.

Ignite 2.6.
Running a single node server on Centos to test this.

First:
Using Intellij to remotely run the sample code from the Ignite Getting
started page here on SQL:
First Ignite SQL Application
https://apacheignite.readme.io/docs/getting-started

This all works fine.  Tables created, data inserted, data read.  All as
expected.

Next:
Using the ODBC 64-bit driver from Windows 10 to connect to the still running
Ignite server to read the same tables (City, Person).   This does not work.

The ODBC driver appears to be able to get meta data - it gets the table
names from the PUBLIC schema and it understands the fields / field counts in
each table.  However, the ODBC driver is unable to perform any select
operations on the tables. See the following stack trace as an example of the
errors I am seeing:


[13:30:19]   ^-- default [initSize=256.0 MiB, maxSize=6.3 GiB,
persistenceEnabled=false]
[13:33:09,424][SEVERE][client-connector-#45][OdbcRequestHandler] Failed to
execute SQL query [reqId=0, req=OdbcQueryExecuteRequest [schema=PUBLIC,
sqlQry=SELECT COUNT(*) FROM ""PUBLIC"".CITY, timeout=0, args=[]]]
class org.apache.ignite.internal.processors.query.IgniteSQLException: Failed
to parse query. Table  not found; SQL statement:
SELECT COUNT(*) FROM ""PUBLIC"".CITY [42102-195]
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.prepareStatementAndCaches(IgniteH2Indexing.java:2026)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.parseAndSplit(IgniteH2Indexing.java:1796)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:1652)

-----------------------

I have tried various things on the Java side to make the Public schema
explicit, such as this:
conn = DriverManager.getConnection("jdbc:ignite:thin://10.60.1.101/PUBLIC");
// conn.setSchema("PUBLIC");

but this does not help with the ODBC problem.  The Java stuff still works
fine.  Select statements in Java can be written like this and they still
work:

 stmt.executeQuery("SELECT p.name, c.name " +
                                 " FROM PUBLIC.Person p, City c " +
                                 " WHERE p.city_id = c.id"))


Any advice on how this should be done (sample code?) is much appreciated.
Thank you.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
limabean limabean
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

In reply to this post by slava.koptilin
Hi,
Here is my ODBC specification.  
The schema is specified as Public and this looks (identical?) like the example in the documentation:



On Thu, Sep 6, 2018 at 11:06 AM Вячеслав Коптилин <[hidden email]> wrote:
Hi,

> I have tried various things on the Java side to make the Public schema explicit, such as this: 
If I'm not mistaken the schema can be specified as a parameter of ODBC connection string.


Thanks,
S.

чт, 6 сент. 2018 г. в 16:59, limabean <[hidden email]>:
Scenario:
64-bit ODBC driver cannot read data created from the Java Thin driver.

Ignite 2.6.
Running a single node server on Centos to test this.

First:
Using Intellij to remotely run the sample code from the Ignite Getting
started page here on SQL:
First Ignite SQL Application
https://apacheignite.readme.io/docs/getting-started

This all works fine.  Tables created, data inserted, data read.  All as
expected.

Next:
Using the ODBC 64-bit driver from Windows 10 to connect to the still running
Ignite server to read the same tables (City, Person).   This does not work.

The ODBC driver appears to be able to get meta data - it gets the table
names from the PUBLIC schema and it understands the fields / field counts in
each table.  However, the ODBC driver is unable to perform any select
operations on the tables. See the following stack trace as an example of the
errors I am seeing:


[13:30:19]   ^-- default [initSize=256.0 MiB, maxSize=6.3 GiB,
persistenceEnabled=false]
[13:33:09,424][SEVERE][client-connector-#45][OdbcRequestHandler] Failed to
execute SQL query [reqId=0, req=OdbcQueryExecuteRequest [schema=PUBLIC,
sqlQry=SELECT COUNT(*) FROM ""PUBLIC"".CITY, timeout=0, args=[]]]
class org.apache.ignite.internal.processors.query.IgniteSQLException: Failed
to parse query. Table  not found; SQL statement:
SELECT COUNT(*) FROM ""PUBLIC"".CITY [42102-195]
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.prepareStatementAndCaches(IgniteH2Indexing.java:2026)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.parseAndSplit(IgniteH2Indexing.java:1796)
        at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:1652)

-----------------------

I have tried various things on the Java side to make the Public schema
explicit, such as this:
conn = DriverManager.getConnection("jdbc:ignite:thin://10.60.1.101/PUBLIC");
// conn.setSchema("PUBLIC");

but this does not help with the ODBC problem.  The Java stuff still works
fine.  Select statements in Java can be written like this and they still
work:

 stmt.executeQuery("SELECT p.name, c.name " +
                                 " FROM PUBLIC.Person p, City c " +
                                 " WHERE p.city_id = c.id"))


Any advice on how this should be done (sample code?) is much appreciated.
Thank you.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

OdbcIgnite.png (107K) Download Attachment
limabean limabean
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

This post was updated on .
In reply to this post by ilya.kasnacheev
Although I specify lower case public in the odbc definition in Windows 10,
the QLIK BI application, on its ODBC connection page, forces an upper case
"PUBLIC" as you can see in the screen shot, and as far as I can tell there
are no options to change that.

QlikOdbcPanel.png
<http://apache-ignite-users.70518.x6.nabble.com/file/t361/QlikOdbcPanel.png


Results:

[15:38:26]   ^-- default [initSize=256.0 MiB, maxSize=6.3 GiB, persistenceEnabled=false]
[15:39:27,924][SEVERE][client-connector-#49][OdbcRequestHandler] Failed to execute SQL query [reqId=0, req=OdbcQueryExecuteRequest [schema=public, sqlQry=SELECT COUNT(*) FROM ""PUBLIC"".CITY, timeout=0, args=[]]]
class org.apache.ignite.internal.processors.query.IgniteSQLException: Failed to set schema for DB connection for thread [schema=public]
        at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.connectionForThread(IgniteH2Indexing.java:543)
        at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.connectionForSchema(IgniteH2Indexing.java:386)



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Igor Sapego-1 Igor Sapego-1
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

It happens, because ODBC returns schema name in quotes,
so seems like QLIK adds its own quotes around it, as it encounters
non standard characters (quotes).

I think, it is a QLIK's error, as our ODBC driver explicitly states, that no
additional quotes should be used around identifiers. And even if it choose
to apply quotes to "PUBLIC" result obviously should not be a ""PUBLIC"".

Best Regards,
Igor


On Thu, Sep 6, 2018 at 6:43 PM limabean <[hidden email]> wrote:
Although I specify lower case public in the odbc definition in Windows 10,
the QLIK BI application, on its ODBC connection page, forces an upper case
"PUBLIC" as you can see in the screen shot, and as far as I can tell there
are no options to change that.

QlikOdbcPanel.png
<http://apache-ignite-users.70518.x6.nabble.com/file/t361/QlikOdbcPanel.png



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
ilya.kasnacheev ilya.kasnacheev
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

Hello!

It's actually very strange that we have quotes around PUBLIC since it's supposed to be used quote-free. I will take a look.

Regards,

--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 14:07, Igor Sapego <[hidden email]>:
It happens, because ODBC returns schema name in quotes,
so seems like QLIK adds its own quotes around it, as it encounters
non standard characters (quotes).

I think, it is a QLIK's error, as our ODBC driver explicitly states, that no
additional quotes should be used around identifiers. And even if it choose
to apply quotes to "PUBLIC" result obviously should not be a ""PUBLIC"".

Best Regards,
Igor


On Thu, Sep 6, 2018 at 6:43 PM limabean <[hidden email]> wrote:
Although I specify lower case public in the odbc definition in Windows 10,
the QLIK BI application, on its ODBC connection page, forces an upper case
"PUBLIC" as you can see in the screen shot, and as far as I can tell there
are no options to change that.

QlikOdbcPanel.png
<http://apache-ignite-users.70518.x6.nabble.com/file/t361/QlikOdbcPanel.png



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Igor Sapego Igor Sapego
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

Well, ODBC applies quotes to all schemas. It makes sense to
check and not apply quotes to PUBLIC, but this won't help in
all other cases, when cache-name-schema is used.

Best Regards,
Igor


On Fri, Sep 7, 2018 at 2:13 PM Ilya Kasnacheev <[hidden email]> wrote:
Hello!

It's actually very strange that we have quotes around PUBLIC since it's supposed to be used quote-free. I will take a look.

Regards,

--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 14:07, Igor Sapego <[hidden email]>:
It happens, because ODBC returns schema name in quotes,
so seems like QLIK adds its own quotes around it, as it encounters
non standard characters (quotes).

I think, it is a QLIK's error, as our ODBC driver explicitly states, that no
additional quotes should be used around identifiers. And even if it choose
to apply quotes to "PUBLIC" result obviously should not be a ""PUBLIC"".

Best Regards,
Igor


On Thu, Sep 6, 2018 at 6:43 PM limabean <[hidden email]> wrote:
Although I specify lower case public in the odbc definition in Windows 10,
the QLIK BI application, on its ODBC connection page, forces an upper case
"PUBLIC" as you can see in the screen shot, and as far as I can tell there
are no options to change that.

QlikOdbcPanel.png
<http://apache-ignite-users.70518.x6.nabble.com/file/t361/QlikOdbcPanel.png



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
ilya.kasnacheev ilya.kasnacheev
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

Maybe we shouldn't bother to quote schemas, assuming that it's the duty of client?

Unfortunately after reading ODBC docs I have no idea, but there's no hints that the result will be quoted.

Regards,
--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 15:38, Igor Sapego <[hidden email]>:
Well, ODBC applies quotes to all schemas. It makes sense to
check and not apply quotes to PUBLIC, but this won't help in
all other cases, when cache-name-schema is used.

Best Regards,
Igor


On Fri, Sep 7, 2018 at 2:13 PM Ilya Kasnacheev <[hidden email]> wrote:
Hello!

It's actually very strange that we have quotes around PUBLIC since it's supposed to be used quote-free. I will take a look.

Regards,

--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 14:07, Igor Sapego <[hidden email]>:
It happens, because ODBC returns schema name in quotes,
so seems like QLIK adds its own quotes around it, as it encounters
non standard characters (quotes).

I think, it is a QLIK's error, as our ODBC driver explicitly states, that no
additional quotes should be used around identifiers. And even if it choose
to apply quotes to "PUBLIC" result obviously should not be a ""PUBLIC"".

Best Regards,
Igor


On Thu, Sep 6, 2018 at 6:43 PM limabean <[hidden email]> wrote:
Although I specify lower case public in the odbc definition in Windows 10,
the QLIK BI application, on its ODBC connection page, forces an upper case
"PUBLIC" as you can see in the screen shot, and as far as I can tell there
are no options to change that.

QlikOdbcPanel.png
<http://apache-ignite-users.70518.x6.nabble.com/file/t361/QlikOdbcPanel.png



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Igor Sapego-1 Igor Sapego-1
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

Ilya,

If we won't bother with quotes, then many other tools will stop working,
as cache-names-schemas MUST be quoted, but they won't be. By the way,
even QLIK will not work with any other schema, except for PUBLIC.

So for now, what I propose is not apply quotes to PUBLIC schema. This is
the only fix I can see here now.

Best Regards,
Igor


On Fri, Sep 7, 2018 at 4:45 PM Ilya Kasnacheev <[hidden email]> wrote:
Maybe we shouldn't bother to quote schemas, assuming that it's the duty of client?

Unfortunately after reading ODBC docs I have no idea, but there's no hints that the result will be quoted.

Regards,
--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 15:38, Igor Sapego <[hidden email]>:
Well, ODBC applies quotes to all schemas. It makes sense to
check and not apply quotes to PUBLIC, but this won't help in
all other cases, when cache-name-schema is used.

Best Regards,
Igor


On Fri, Sep 7, 2018 at 2:13 PM Ilya Kasnacheev <[hidden email]> wrote:
Hello!

It's actually very strange that we have quotes around PUBLIC since it's supposed to be used quote-free. I will take a look.

Regards,

--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 14:07, Igor Sapego <[hidden email]>:
It happens, because ODBC returns schema name in quotes,
so seems like QLIK adds its own quotes around it, as it encounters
non standard characters (quotes).

I think, it is a QLIK's error, as our ODBC driver explicitly states, that no
additional quotes should be used around identifiers. And even if it choose
to apply quotes to "PUBLIC" result obviously should not be a ""PUBLIC"".


Best Regards,
Igor


On Thu, Sep 6, 2018 at 6:43 PM limabean <[hidden email]> wrote:
Although I specify lower case public in the odbc definition in Windows 10,
the QLIK BI application, on its ODBC connection page, forces an upper case
"PUBLIC" as you can see in the screen shot, and as far as I can tell there
are no options to change that.

QlikOdbcPanel.png
<http://apache-ignite-users.70518.x6.nabble.com/file/t361/QlikOdbcPanel.png



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
ilya.kasnacheev ilya.kasnacheev
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

Hello!

Yes, I'm pretty confident that PUBLIC should work without quotes. I'm even not sure that it would work even with ordinary double quotes set.

Regards,
--
Ilya Kasnacheev


пн, 10 сент. 2018 г. в 14:28, Igor Sapego <[hidden email]>:
Ilya,

If we won't bother with quotes, then many other tools will stop working,
as cache-names-schemas MUST be quoted, but they won't be. By the way,
even QLIK will not work with any other schema, except for PUBLIC.

So for now, what I propose is not apply quotes to PUBLIC schema. This is
the only fix I can see here now.

Best Regards,
Igor


On Fri, Sep 7, 2018 at 4:45 PM Ilya Kasnacheev <[hidden email]> wrote:
Maybe we shouldn't bother to quote schemas, assuming that it's the duty of client?

Unfortunately after reading ODBC docs I have no idea, but there's no hints that the result will be quoted.

Regards,
--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 15:38, Igor Sapego <[hidden email]>:
Well, ODBC applies quotes to all schemas. It makes sense to
check and not apply quotes to PUBLIC, but this won't help in
all other cases, when cache-name-schema is used.

Best Regards,
Igor


On Fri, Sep 7, 2018 at 2:13 PM Ilya Kasnacheev <[hidden email]> wrote:
Hello!

It's actually very strange that we have quotes around PUBLIC since it's supposed to be used quote-free. I will take a look.

Regards,

--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 14:07, Igor Sapego <[hidden email]>:
It happens, because ODBC returns schema name in quotes,
so seems like QLIK adds its own quotes around it, as it encounters
non standard characters (quotes).

I think, it is a QLIK's error, as our ODBC driver explicitly states, that no
additional quotes should be used around identifiers. And even if it choose
to apply quotes to "PUBLIC" result obviously should not be a ""PUBLIC"".


Best Regards,
Igor


On Thu, Sep 6, 2018 at 6:43 PM limabean <[hidden email]> wrote:
Although I specify lower case public in the odbc definition in Windows 10,
the QLIK BI application, on its ODBC connection page, forces an upper case
"PUBLIC" as you can see in the screen shot, and as far as I can tell there
are no options to change that.

QlikOdbcPanel.png
<http://apache-ignite-users.70518.x6.nabble.com/file/t361/QlikOdbcPanel.png



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Igor Sapego-1 Igor Sapego-1
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

I've filed a ticket: [1]


Best Regards,
Igor


On Mon, Sep 10, 2018 at 2:56 PM Ilya Kasnacheev <[hidden email]> wrote:
Hello!

Yes, I'm pretty confident that PUBLIC should work without quotes. I'm even not sure that it would work even with ordinary double quotes set.

Regards,
--
Ilya Kasnacheev


пн, 10 сент. 2018 г. в 14:28, Igor Sapego <[hidden email]>:
Ilya,

If we won't bother with quotes, then many other tools will stop working,
as cache-names-schemas MUST be quoted, but they won't be. By the way,
even QLIK will not work with any other schema, except for PUBLIC.

So for now, what I propose is not apply quotes to PUBLIC schema. This is
the only fix I can see here now.

Best Regards,
Igor


On Fri, Sep 7, 2018 at 4:45 PM Ilya Kasnacheev <[hidden email]> wrote:
Maybe we shouldn't bother to quote schemas, assuming that it's the duty of client?

Unfortunately after reading ODBC docs I have no idea, but there's no hints that the result will be quoted.

Regards,
--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 15:38, Igor Sapego <[hidden email]>:
Well, ODBC applies quotes to all schemas. It makes sense to
check and not apply quotes to PUBLIC, but this won't help in
all other cases, when cache-name-schema is used.

Best Regards,
Igor


On Fri, Sep 7, 2018 at 2:13 PM Ilya Kasnacheev <[hidden email]> wrote:
Hello!

It's actually very strange that we have quotes around PUBLIC since it's supposed to be used quote-free. I will take a look.

Regards,

--
Ilya Kasnacheev


пт, 7 сент. 2018 г. в 14:07, Igor Sapego <[hidden email]>:
It happens, because ODBC returns schema name in quotes,
so seems like QLIK adds its own quotes around it, as it encounters
non standard characters (quotes).

I think, it is a QLIK's error, as our ODBC driver explicitly states, that no
additional quotes should be used around identifiers. And even if it choose
to apply quotes to "PUBLIC" result obviously should not be a ""PUBLIC"".


Best Regards,
Igor


On Thu, Sep 6, 2018 at 6:43 PM limabean <[hidden email]> wrote:
Although I specify lower case public in the odbc definition in Windows 10,
the QLIK BI application, on its ODBC connection page, forces an upper case
"PUBLIC" as you can see in the screen shot, and as far as I can tell there
are no options to change that.

QlikOdbcPanel.png
<http://apache-ignite-users.70518.x6.nabble.com/file/t361/QlikOdbcPanel.png



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
limabean limabean
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

Thank you very much for the thorough discussion/explanation and pending fix
for public schemas.  Much appreciated !
 
As an aside, I also contacted QLIK to see if they will fix their product
behavior, which does not seem correct to me either.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Igor Sapego-1 Igor Sapego-1
Reply | Threaded
Open this post in threaded view
|

Re: How to create tables with JDBC, read with ODBC?

Nice to hear.

Please, keep us updated about what QLIK thinks about the issue.

Thank you in advance

Best Regards,
Igor


On Mon, Sep 10, 2018 at 10:50 PM limabean <[hidden email]> wrote:
Thank you very much for the thorough discussion/explanation and pending fix
for public schemas.  Much appreciated !

As an aside, I also contacted QLIK to see if they will fix their product
behavior, which does not seem correct to me either.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/