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

fix nulls first regression #94

Merged
merged 2 commits into from
Jul 24, 2023

Conversation

dot2dotseurat
Copy link
Contributor

@dot2dotseurat dot2dotseurat commented Jul 21, 2023

Null ordering is large in the postgres dialect and previously we overrode this with #66 but it was reverting when we bumped sqlglot versions #82

The only way I see to get around this is to make a new Dialect and inherit Postgres and edit NULL_ORDERING on that.

class Postgres(Dialect):
    INDEX_OFFSET = 1
    NULL_ORDERING = "nulls_are_large"

https://github.com/tobymao/sqlglot/blob/46b5dfa09bba7c339dd8b0bd077455946dec8d8d/sqlglot/dialects/postgres.py#L211

Copy link
Contributor

@antonio-mendes antonio-mendes left a comment

Choose a reason for hiding this comment

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

LGTM @dot2dotseurat , can I just ask you to bump this

version = "0.34.2"
to 0.34.3 as well?

Feel free to merge afterwards and I can then re-deploy 👍

@antonio-mendes antonio-mendes merged commit 5036296 into main Jul 24, 2023
@antonio-mendes antonio-mendes deleted the meghan/llm-19-fix-regression-on-harmonizer branch July 24, 2023 18:54
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