Uploaded image for project: 'Calcite'
  1. Calcite
  2. CALCITE-3365

Don't require use of JdbcSchema in QuerySqlStatisticProvider

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.22.0
    • None

    Description

      We're trying to pass in schema data manually to process queries for BigQuery, but that causes problems in the QuerySqlStatisticProvider because it requires a JdbcSchema in order to get the dialect and dataSource, as well as using a Jdbc Builder.

      I propose refactoring QuerySqlStatisticProvider to grab the dialect and dataSource using unwrap on the schema instead, so that any schema that implements unwrap methods for these types will work with QuerySqlStatisticProvider. As well as using a generic RelBuilder, instead of a JDBC_BUILDER.

      cc julianhyde since we have been discussing this

      I've opened a PR at https://github.com/apache/calcite/pull/1467

      Attachments

        Issue Links

          Activity

            People

              julianhyde Julian Hyde
              lindseycat Lindsey Meyer
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m