We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a1176c6 commit 4574eb9Copy full SHA for 4574eb9
src/backend/tcop/postgres.c
@@ -815,15 +815,15 @@ pg_rewrite_query(Query *query)
815
816
foreach(lc, querytree_list)
817
{
818
- Query *query = lfirst_node(Query, lc);
819
- char *str = nodeToString(query);
+ Query *curr_query = lfirst_node(Query, lc);
+ char *str = nodeToString(curr_query);
820
Query *new_query = stringToNodeWithLocations(str);
821
822
/*
823
* queryId is not saved in stored rules, but we must preserve it
824
* here to avoid breaking pg_stat_statements.
825
*/
826
- new_query->queryId = query->queryId;
+ new_query->queryId = curr_query->queryId;
827
828
new_list = lappend(new_list, new_query);
829
pfree(str);
0 commit comments