Skip to content

when connection to snowflake, ALTER SESSION SET JDBC_QUERY_RESULT_FORMAT='JSON'; is required #65

@robert-s-lee

Description

@robert-s-lee

without ALTER SESSION SET JDBC_QUERY_RESULT_FORMAT='JSON';, without it, : JDBC driver internal error: Fail to retrieve row count for first arrow chunk: null. is given.

 1> select * from information_schema.databases;
SQL Exception(s) Encountered:
[State: XX000][Code: 200001]: JDBC driver internal error: Fail to retrieve row count for first arrow chunk: null.
 1> ALTER SESSION SET JDBC_QUERY_RESULT_FORMAT='JSON';
ok. (total: 0.138s)
 1> select * from information_schema.databases;
+-----------------------+----------------+--------------+---------------------------------------------------+-------------------------+-------------------------+----------------+
| DATABASE_NAME         | DATABASE_OWNER | IS_TRANSIENT | COMMENT                                           | CREATED                 | LAST_ALTERED            | RETENTION_TIME |
+-----------------------+----------------+--------------+---------------------------------------------------+-------------------------+-------------------------+----------------+
| SNOWFLAKE_SAMPLE_DATA | ACCOUNTADMIN   | NO           | Provided by Snowflake during account provisioning | 2023-04-30 17:10:15.739 | 2023-04-30 17:10:15.739 |              1 |
| arcsrc                | ACCOUNTADMIN   | NO           | [NULL]                                            | 2023-04-30 17:36:52.839 | 2023-04-30 17:36:52.897 |              1 |
+-----------------------+----------------+--------------+---------------------------------------------------+-------------------------+-------------------------+----------------+
2 rows in results(first row: 0.519s; total: 0.520s)
 1> select * from t1;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions