Skip to content

Support prepared statement parameter type inference #4700

@avantgardnerio

Description

@avantgardnerio

Is your feature request related to a problem or challenge? Please describe what you are trying to do.

When implementing FlightSQL, it was observed that the prepare ... syntax that our prepared statement code expects is not present. This is problematic, because there is no syntax from which to find type declarations. When comparing to how the JDBC client behaves, it appears to expect parameter types to be inferred.

Describe the solution you'd like

  1. Don't require prepare ... syntax (just allow a regular query to be prepared as a statement)
  2. Infer the parameter types
  3. Add a method to return inferred types

Describe alternatives you've considered

  1. Have all existing JDBC code rewritten to support the model as present in DataFusion today
  2. Do not support prepared statements
  3. Always return a generic type like "String" or "Object" and coerce

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions