Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use ndc-postgres query engine #57

Merged
merged 18 commits into from
Nov 7, 2023

Conversation

danieljharvey
Copy link
Collaborator

@danieljharvey danieljharvey commented Nov 6, 2023

What

ndc-postgres has changed a bunch since we forked from it. This grabs the ndc-postgres query engine, and then fixes it for SQLServer again. All the existing tests pass, there are probably new ones we can add as we check new functionality such as Native Queries.

How

Copy and paste and then fix things.

Minimal changes were made in the ndc-sqlserver crate, only enough to get everything working

@danieljharvey danieljharvey force-pushed the djh/copy-pasta-postgres-query-engine branch from c6eb17a to 252206c Compare November 6, 2023 17:17
@danieljharvey danieljharvey requested a review from soupi November 6, 2023 17:23
Copy link
Contributor

@plcplc plcplc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Quite an amount of copy pasta, with only a few Postgres leftovers that I could find.

Considering how relatively small the difference is it'd be great in the future to distill some of those shared chunks into a shared library.

crates/query-engine/sql/src/sql/ast.rs Outdated Show resolved Hide resolved
crates/query-engine/sql/src/sql/convert.rs Outdated Show resolved Hide resolved
crates/query-engine/sql/src/sql/helpers.rs Outdated Show resolved Hide resolved
crates/query-engine/sql/src/sql/helpers.rs Outdated Show resolved Hide resolved
crates/query-engine/sql/src/sql/string.rs Show resolved Hide resolved
configuration: &DeploymentConfiguration,
) -> Result<DeploymentConfiguration, connector::ValidateError> {
if configuration.version != 1 {
config: DeploymentConfiguration,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I take it that the current Sql Server implementation does not include any introspection and just relies on the deployment files from Postgres for e.g tests etc?

If it did have an introspection ability that would have to updated substantially as well with this new change dump.

Copy link
Collaborator Author

@danieljharvey danieljharvey Nov 7, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

100% - once introspection goes in I guess these types will change a bunch.

@danieljharvey danieljharvey added this pull request to the merge queue Nov 7, 2023
Merged via the queue into main with commit d7816b1 Nov 7, 2023
6 checks passed
@SamirTalwar SamirTalwar deleted the djh/copy-pasta-postgres-query-engine branch November 20, 2023 17:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants