mirror of
https://github.com/hasura/graphql-engine.git
synced 2025-01-05 22:34:22 +03:00
862ad8e0dc
This PR updated ndc-models to the latest version on main. This version is still a 0.1.x version, but it now includes all the [new newtypes](https://github.com/hasura/ndc-spec/pull/156) that wrap previously stringly-typed things. For example, `ArgumentName`, `FieldName`, etc. This pervades across the entire engine, but thankfully the changes are mostly mechanical repetitive changes. Usually you will see conversions from `String`-typed variables into the newtypes using this sort of form: `FieldName::from(string.as_str())`, which is the most efficient way copying the value (the str slice is copied). Or you will see usages of the newtype as a raw string by `.as_str()`-ing it. Converting the newtypes into a String can be done with `.into()` if owned, but if referenced `.as_str().to_owned()` performs the clone and type conversion. Other changes: * A few minor instances of `ok_or()` usages (or similar) have been converted into lazy error construction variants (eg `ok_or_else()`) V3_GIT_ORIGIN_REV_ID: 64a371ae6197ef3be98a6f7cdc4052d654a43da0 |
||
---|---|---|
.. | ||
src | ||
Cargo.toml | ||
readme.md |
SQL Interface
An experimental SQL interface over OpenDD models. This is mostly targeted at AI use cases for now - GenAI models are better at generating SQL queries than GraphQL queries.
This is implemented using the Apache DataFusion Query Engine by deriving the SQL
metadata for datafusion from Open DDS metadata. As the implementation currently
stands, once we get a LogicalPlan
from datafusion we replace TableScan
s with
NDC queries to the underlying connector. There is a rudimentary optimizer that
pushes down projections to the ndc query so that we don't fetch all the columns
of a collection.