Bug#104121: Ensure that PREPAREd statements are shown correctly in PERFORMANCE_SCHEMA.THREADS table #5060
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This reverts the deletion of several lines from
sql/sql_class.cc
in afcaac4#diff-65c68b03ca220f14939f817d3c9cfe7767580750f9ef47876b383780a0fd82c3L4357.That deletion caused a regression:
PERFORMANCE_SCHEMA.THREADS
is no longer correctly updated while executing aPREPARE
d statement. Detailed example in https://bugs.mysql.com/bug.php?id=104121The one-line patch proposed as a fix in https://bugs.mysql.com/bug.php?id=104121#c513825 has the unwanted side effect of overwriting
performance_schema.events_statements_history.SQL_TEXT
(causing it to appear asNULL
).We verified that this change does not undo the intended effect of the original commit. Passwords (still) do not leak into the
PERFORMANCE_SCHEMA.THREADS
table with this change: