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

fix exception when calling getWarnings #55

Merged
merged 1 commit into from Jun 23, 2023

Conversation

cdalexndr
Copy link
Contributor

@cdalexndr cdalexndr commented Jun 12, 2023

Return no sql warnings.

closes #54

@wey-gu wey-gu requested a review from Young-Flash June 13, 2023 02:03
public SQLWarning getWarnings() throws SQLException {
throw ExceptionBuilder.buildUnsupportedOperationException();
public SQLWarning getWarnings() {
return null;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you explain why always return null here?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This issue answers the question very well #54.
Clickhouse jdbc client is also written in this way and returns null

https://github.com/ClickHouse/clickhouse-java/blob/main/clickhouse-jdbc/src/main/java/com/clickhouse/jdbc/internal/ClickHouseStatementImpl.java
line 628

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Directly returning null may not be the best approach. It would be better if we could return SQLWarning. I'd like to merge this PR first. How do you think, @wey-gu?

Thank you for your contribution.

@Young-Flash Young-Flash merged commit d13993a into nebula-contrib:master Jun 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Method getWarnings in class com.vesoft.nebula.jdbc.statement.NebulaStatementImpl is not supported.
3 participants