-
Notifications
You must be signed in to change notification settings - Fork 2.8k
change descending ordering to nulls first (fix #1008) #1009
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
Conversation
|
Beep boop! 🤖 Hey @slowr, thanks for your PR! One of my human friends will review this PR and get back to you as soon as possible. 🕐 Stay awesome! 😎 |
|
Review app available at: https://hge-ci-pull-1009.herokuapp.com |
|
@slowr We decided to change the default behavior of asc
asc_nulls_last # same as asc
asc_nulls_first
desc
desc_nulls_first # same as desc
desc_nulls_lastWill you be willing to make these changes? If so, you don't need to add another value called |
|
@0x777 Should I make the change to the files on this PR and change descriptions etc? |
|
Review app available at: https://hge-ci-pull-1009.herokuapp.com |
|
Review app available at: https://hge-ci-pull-1009.herokuapp.com |
|
Beep boop! 🤖 Whoa! 🎉 🎉 💃 Awesome work @slowr! 💪 🏆 All of us at Hasura ❤️ what you did. Thanks again 🤗 |
|
Review app https://hge-ci-pull-1009.herokuapp.com is deleted |
<!-- The PR description should answer 2 important questions: --> ### What Expose operation type in query and explain endpoints. V3_GIT_ORIGIN_REV_ID: 852276fc04b3173a9364e593c33d1ceb6bd88064
Description
Auto-generated queries when there is an order function they includeNULLS FIRSTorNULLS LAST.Descending ordering auto-generated queries include
NULLS LASTinstead of postgres default;NULLS FIRSTThis tends to mess-up indexing tables as mentioned in #1008 and #657
What component does this PR affect?
Requires changes from other components? If yes, please mark the components:
Related Issue
#1008
#657
Solution and Design
A new enum is added to avoid NULLS ordering (FIRST, LAST) in the auto-generated queries. Decided to introduce new enum and not change the default implementation to keep backwards compatibility.Change the default NULLs ordering for desc to be
NULLS FIRSTso it follows postgres specification.Type
Checklist: