Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After upgrade from 11.21.19, jdbc couldn't list tables for non sys users #4038

Closed
monetdb-team opened this issue Nov 30, 2020 · 0 comments
Closed

Comments

@monetdb-team
Copy link

@monetdb-team monetdb-team commented Nov 30, 2020

Date: 2016-07-21 12:38:57 +0200
From: Gatis Ozolins <<g.ozolins>>
To: SQL devs <>
Version: 11.23.3 (Jun2016)
CC: martin.van.dinther

Last updated: 2016-10-13 10:03:49 +0200

Comment 22249

Date: 2016-07-21 12:38:57 +0200
From: Gatis Ozolins <<g.ozolins>>

User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:47.0) Gecko/20100101 Firefox/47.0
Build Identifier:

I had to grant access to sys.environment and sys.table_types:
grant select on sys.environment to public;
grant select on sys.table_types to public;

Otherwise I couldn't get to list all tables in DBeaver as I was getting:
java.lang.NullPointerException
at java.lang.String.compareTo(Unknown Source)
at nl.cwi.monetdb.jdbc.MonetDatabaseMetaData.getTables(MonetDatabaseMetaData.java:1933)

I traced it down to this line:
boolean preJul2015 = ("11.19.15".compareTo(getDatabaseProductVersion()) >= 0);

Did I had to do additional steps after DB upgrade?

Reproducible: Always

Comment 22250

Date: 2016-07-21 12:49:23 +0200
From: @sjoerdmullender

In the upcoming Jun2016-SP1 release, the function sys.env() will be granted public execution privileges, so that should fix this problem.

You can test this by trying out the relase candidate which is already available at http://dev.monetdb.org/downloads/testing/

Comment 22393

Date: 2016-09-29 13:02:27 +0200
From: MonetDB Mercurial Repository <>

Changeset b3ca1157be73, made by Martin van Dinther martin.van.dinther@monetdbsolutions.com in the monetdb-java repo, refers to this bug.

For complete details, see http://dev.monetdb.org/hg/monetdb-java?cmd=changeset;node=b3ca1157be73

Changeset description:

Improve DatabaseMetaData.getDatabaseProductVersion() to never return a null String.
This prevents runtime NullPointerException in getTables() and getTableTypes().
Also improved error reporting when JDBC driver failed to fetch the value of environment variable monet_version
as reported in bug #4038.
It will now throw an SQLException with the error message.

Comment 24488

Date: 2016-10-13 10:03:49 +0200
From: @sjoerdmullender

Jun2016-SP2 has been released.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant