mirror of
https://github.com/postgres/postgres.git
synced 2025-06-16 06:01:02 +03:00
Fix crash when trying to display a NOTIFY rule action.
Fixes oversight in commit 2ffa740be9
.
Per report from Josh Kupershmidt.
I think we've broken this case before, so let's add a regression test
this time.
This commit is contained in:
@ -2564,14 +2564,19 @@ set_deparse_for_query(deparse_namespace *dpns, Query *query,
|
||||
dpns->rtable_columns = lappend(dpns->rtable_columns,
|
||||
palloc0(sizeof(deparse_columns)));
|
||||
|
||||
/* Detect whether global uniqueness of USING names is needed */
|
||||
dpns->unique_using = has_unnamed_full_join_using((Node *) query->jointree);
|
||||
/* If it's a utility query, it won't have a jointree */
|
||||
if (query->jointree)
|
||||
{
|
||||
/* Detect whether global uniqueness of USING names is needed */
|
||||
dpns->unique_using =
|
||||
has_unnamed_full_join_using((Node *) query->jointree);
|
||||
|
||||
/*
|
||||
* Select names for columns merged by USING, via a recursive pass over the
|
||||
* query jointree.
|
||||
*/
|
||||
set_using_names(dpns, (Node *) query->jointree);
|
||||
/*
|
||||
* Select names for columns merged by USING, via a recursive pass over
|
||||
* the query jointree.
|
||||
*/
|
||||
set_using_names(dpns, (Node *) query->jointree);
|
||||
}
|
||||
|
||||
/*
|
||||
* Now assign remaining column aliases for each RTE. We do this in a
|
||||
|
Reference in New Issue
Block a user