-
Notifications
You must be signed in to change notification settings - Fork 408
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make ai::search have integrated sort and hit indexes (#7242)
Tweak ai::search codegen to make it hit the index reliably even with filtering NULLs out. It seems that postgres *can* sometimes manage to use an ORDER BY index even when the function call isn't directly in the ORDER BY, but it is much more fragile (broken by adding the NULL check in #7223, for one). Making ai::search return sorted output makes it easy to hit the indexes and improves ergonomics. Also: * Compile the arguments in the enclosing scope, which helps us hit the index in more complex scenarios (like a cast from json) * Make sure to export a source rvar for `.object`
- Loading branch information
Showing
4 changed files
with
111 additions
and
14 deletions.
There are no files selected for viewing
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
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
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
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