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
Allow Union Queries for Squirrel #320
Open
ovadbar
wants to merge
10
commits into
Masterminds:master
Choose a base branch
from
ovadbar:master
base: master
Could not load branches
Branch not found: {{ refName }}
Could not load tags
Nothing to show
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains 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
Add UNION
nyergler
added a commit
to polytomic/squirrel
that referenced
this pull request
Oct 20, 2022
This merges the fix for Masterminds#320.
Is this going to be merged? |
Is it going to be merged soon by any chance? |
@mikeschinkel please when is this going to merged? This is really critical for us. |
This is kind of a hack to do it without my merge. You have to include the order and limit separately.
|
et
added a commit
to highlight/highlight
that referenced
this pull request
Mar 2, 2023
## Summary <!-- Ideally, there is an attached Linear ticket that will describe the "why". If relevant, use this section to call out any additional information you'd like to _highlight_ to the reviewer. --> This PR adds support to filter by the log level (internally called `SeverityText`). Will follow up for adding support for trace id and other non-custom attributes. This PR also replaces [squirrel](https://github.com/Masterminds/squirrel) with [go-sqlbuilder](https://github.com/huandu/go-sqlbuilder). There's a couple reasons for this: * squirrel is in [maintenance](https://github.com/Masterminds/squirrel#squirrel-is-complete) mode where as go-sqlbuilder has active development. * squirrel lacks `UNION` support. We'll need this for permalinking ([example](https://github.com/highlight/highlight/pull/4417/files#diff-e913069aa4c9c7492c6180d43d70b4d9200d25b074a1b346c87319b510b0327fR72-R95)). Per the previous point, it doesn't seem like squirrel will add union support even with a [PR ready](Masterminds/squirrel#320 (comment)). * seems like squirrel has some design pitfalls (see [FAQ](https://github.com/huandu/go-sqlbuilder#whats-the-difference-between-this-package-and-squirrel)). ## How did you test this change? <!-- Frontend - Leave a screencast or a screenshot to visually describe the changes. --> Unit tests added for testing level filtering. Our existing tests should cover the squirrel -> go-sqlbuilder transition Click test: ![Kapture 2023-03-01 at 16 25 41](https://user-images.githubusercontent.com/58678/222289818-aed17785-d41e-4603-92f0-9def5f7ba74f.gif) ## Are there any deployment considerations? <!-- Backend - Do we need to consider migrations or backfilling data? --> N/A
🤔 |
[Masterminds#82] Added FROM clause to update builder (Masterminds#256)
🤔 |
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.
Added some tests and a fix for generating union queries.