Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit ee3ef4a

Browse files
committed
Improve comment of DeallocateStmt->isall
This field is not used directly in the code, but it is important for query jumbling to be able to make a difference between a named DEALLOCATE and DEALLOCATE ALL (see bb45156). This behavior is tracked in the regression tests of pg_stat_statements, but the reason why this field is important can be easily missed, as a recent discussion has proved, so let's improve its comment to document the reason why it needs to be around. Wording has been suggested by Tom Lane Discussion: https://postgr.es/m/Zih1ATt37YFda8_p@paquier.xyz
1 parent e51c2a4 commit ee3ef4a

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/include/nodes/parsenodes.h

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4070,7 +4070,12 @@ typedef struct DeallocateStmt
40704070
NodeTag type;
40714071
/* The name of the plan to remove, NULL if DEALLOCATE ALL */
40724072
char *name pg_node_attr(query_jumble_ignore);
4073-
/* true if DEALLOCATE ALL */
4073+
4074+
/*
4075+
* True if DEALLOCATE ALL. This is redundant with "name == NULL", but we
4076+
* make it a separate field so that exactly this condition (and not the
4077+
* precise name) will be accounted for in query jumbling.
4078+
*/
40744079
bool isall;
40754080
/* token location, or -1 if unknown */
40764081
ParseLoc location pg_node_attr(query_jumble_location);

0 commit comments

Comments
 (0)