-
Notifications
You must be signed in to change notification settings - Fork 103
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove dependency to shell scripts for EXPLAIN output filtering
pg_hint_plan has depended for a long time on a set of non-portable shell scripts to filter the output of the plans of any unstable output, like costs or widths. This had the disadvantage to be usable only on Linux, while depending on \o and temporary output files. This is replaced in this commit by a solution closer to PostgreSQL upstream, where we use a PL/pgSQL function to process the EXPLAIN queries whose output need to be stabilized. The style used in this commit may arguably be improved more in the future, but the changes done here make the diffs more pallatable than anything I have considered, with all the plans generated remaining the same. Some queries that included quotes in ut-R required a couple more quotes to work in the filtering function. Some extra CONTEXT messages coming from the filtering function are generated, as well as some extra LOG messages for cases related unused indexes, but let's live with that for now. Author: Yogesh Sharma, Michael Paquier Backpatch-through: 17 Per pull request #198 and issue #181.
- Loading branch information
Showing
17 changed files
with
1,301 additions
and
1,299 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
Oops, something went wrong.