yukkit opened a new issue, #180:
URL: https://github.com/apache/arrow-java/issues/180

   ### Describe the usage question you have. Please include as many useful 
details as  possible.
   
   
   
   When I call the `getTables` interface, I get an error
   ```
   java.sql.SQLException: Failed to transform VectorSchemaRoot.
   
        at 
org.apache.arrow.driver.jdbc.ArrowFlightJdbcFlightStreamResultSet.executeForCurrentFlightStream(ArrowFlightJdbcFlightStreamResultSet.java:150)
        at 
org.apache.arrow.driver.jdbc.ArrowFlightJdbcFlightStreamResultSet.execute(ArrowFlightJdbcFlightStreamResultSet.java:139)
        at 
org.apache.arrow.driver.jdbc.ArrowFlightJdbcFlightStreamResultSet.fromFlightInfo(ArrowFlightJdbcFlightStreamResultSet.java:105)
        at 
org.apache.arrow.driver.jdbc.ArrowDatabaseMetadata.getTables(ArrowDatabaseMetadata.java:902)
   ```
   
   My server returns the result as follows
   ```
   SELECT
                   TABLE_TENANT as TABLE_CAT,
                   TABLE_DATABASE as TABLE_SCHEM,
                   TABLE_NAME,
                   TABLE_TYPE
               FROM
                   INFORMATION_SCHEMA.TABLES
               WHERE TABLE_TENANT = 'cnosdb' AND TABLE_DATABASE LIKE 'public' 
AND TABLE_NAME LIKE '%' AND TABLE_TYPE IN ('TABLE')
               ORDER BY
                   TABLE_TYPE, TABLE_CAT, TABLE_SCHEM, TABLE_NAME
   ```
   
   By the code, I found that
   
   - Convert `catalog_name` to `TABLE_CAT` in the 
`ArrowDatabaseMetadata.getCatalogs` api.
   - Convert `db_schema_name` to `TABLE_SCHEM` in the 
`ArrowDatabaseMetadata.getSchemas` api.
   - ......
   
   For the above, can I think that the ResultSet Schema of my `getSchemas` 
implementation must be `db_schema_name`, `catalog_name` instead of 
`TABLE_SCHEM`, `TABLE_CATALOG`. The same goes for other API?
   
   
   
   
   ### Component(s)
   
   Java


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@arrow.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to