Bug #83305 Update FLUSH TABLES documentation to discuss the prepared statement cache
Submitted: 8 Oct 2016 8:18 Modified: 31 Jul 2017 14:23
Reporter: monty solomon Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Documentation Severity:S3 (Non-critical)
Version:5.6, 5.7 OS:Any
Assigned to: CPU Architecture:Any

[8 Oct 2016 8:18] monty solomon
Description:
The documentation of FLUSH TABLES discusses the query cache but not the prepared statement cache.

How to repeat:
View the documentation for FLUSH TABLES

FLUSH Syntax
https://dev.mysql.com/doc/refman/5.7/en/flush.html

FLUSH TABLES

Closes all open tables, forces all tables in use to be closed, and flushes the query cache. FLUSH TABLES also removes all query results from the query cache, like the RESET QUERY CACHE statement.

Caching of Prepared Statements and Stored Programs
https://dev.mysql.com/doc/refman/5.7/en/statement-caching.html

To avoid problems caused by metadata changes to tables or views referred to by the prepared statement, the server detects these changes and automatically reprepares the statement when it is next executed. That is, the server reparses the statement and rebuilds the internal structure. Reparsing also occurs after referenced tables or views are flushed from the table definition cache, either implicitly to make room for new entries in the cache, or explicitly due to FLUSH TABLES.

Suggested fix:
Update the FLUSH TABLES documentation.
[12 Oct 2016 11:16] MySQL Verification Team
Hello Monty,

Thank you for the report.

Thanks,
Umesh
[31 Jul 2017 14:23] Paul DuBois
Posted by developer:
 
Page updated.