postgres connector: implement "like" filter#1764
Merged
Conversation
2e836a5 to
6477133
Compare
tomhoule
commented
Jun 11, 2024
| """ nin: [String] | ||
| not: StringSearchFilterInput | ||
| """ | ||
| The string matches the given pattern. |
Contributor
Author
There was a problem hiding this comment.
I don't understand what's happening with the leading whitespace here.
Contributor
There was a problem hiding this comment.
Wonder if the graphql-parser roundtrip is messing it up. Looks like graphql-parser didn't handle block strings properly prior to this PR: graphql-rust/graphql-parser#75 (which is unreleased as far as I can see)
tomhoule
commented
Jun 11, 2024
| create_array_update_type(input_ctx, TypeKind::Scalar(scalar), output_ctx); | ||
| } | ||
|
|
||
| registrer_string_filters(input_ctx, output_ctx); |
Contributor
Author
There was a problem hiding this comment.
s/registrer/register
obmarg
approved these changes
Jun 11, 2024
It produces a `LIKE` clause (https://www.postgresql.org/docs/current/functions-matching.html). The feature request was for a `contains` filter, but: 1. The `contains` name is already used for the array membership filter 2. "like" better matches database terminology 3. LIKE is more powerful. It can also serve as `startsWith`, `endsWith`, ... closes GB-6869
6477133 to
fe074d8
Compare
tomhoule
added a commit
that referenced
this pull request
Jun 13, 2024
Features - You can now filter on text columns with the LIKE operator on the postgres connector (https://www.postgresql.org/docs/current/functions-matching.html). #1764 - The postgres connector now uses a connection pool instead of a single connection in `grafbase start`. #1771 - The postgres connector now supports multiple relations between two tables. See the pull request (#1770) for an example. - Fixed a bug with enum values sent to subgraphs in `grafbase dev` for federated graphs. #1766
Merged
tomhoule
added a commit
that referenced
this pull request
Jun 13, 2024
Features - You can now filter on text columns with the LIKE operator on the postgres connector (https://www.postgresql.org/docs/current/functions-matching.html). #1764 - The postgres connector now uses a connection pool instead of a single connection in `grafbase start`. #1771 - The postgres connector now supports multiple relations between two tables. See the pull request (#1770) for an example. - Fixed a bug with enum values sent to subgraphs in `grafbase dev` for federated graphs. #1766 - Expand the scope of files watched for changes in `grafbase dev`. #1774
tomhoule
added a commit
that referenced
this pull request
Jun 13, 2024
Features - You can now filter on text columns with the LIKE operator on the postgres connector (https://www.postgresql.org/docs/current/functions-matching.html). #1764 - The postgres connector now uses a connection pool instead of a single connection in `grafbase start`. #1771 - The postgres connector now supports multiple relations between two tables. See the pull request (#1770) for an example. - Fixed a bug with enum values sent to subgraphs in `grafbase dev` for federated graphs. #1766 - Expand the scope of files watched for changes in `grafbase dev`. #1774
tomhoule
added a commit
that referenced
this pull request
Jun 13, 2024
Features - You can now filter on text columns with the LIKE operator on the postgres connector (https://www.postgresql.org/docs/current/functions-matching.html). #1764 - The postgres connector now uses a connection pool instead of a single connection in `grafbase start`. #1771 - The postgres connector now supports multiple relations between two tables. See the pull request (#1770) for an example. - Fixed a bug with enum values sent to subgraphs in `grafbase dev` for federated graphs. #1766 - Expand the scope of files watched for changes in `grafbase dev`. #1774
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
It produces a
LIKEclause (https://www.postgresql.org/docs/current/functions-matching.html).The feature request was for a
containsfilter, but:containsname is already used for the array membership filterstartsWith,endsWith, ...closes GB-6869