Bug #82723 COMPRESSION column of I_S.INNODB_SYS_TABLESPACES is still used in the manual
Submitted: 25 Aug 2016 11:54 Modified: 8 Sep 2016 19:58
Reporter: Valeriy Kravchuk Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Documentation Severity:S3 (Non-critical)
Version:5.7 OS:Any
Assigned to: CPU Architecture:Any
Tags: compression, information_schema, innodb_sys_tablespaces

[25 Aug 2016 11:54] Valeriy Kravchuk
Description:
Manual (https://dev.mysql.com/doc/refman/5.7/en/innodb-sys-tablespaces-table.html) says:

"COMPRESSION	The current tablespace setting for page compression (Zlib, Lz4, or None). A table may contain a mix of pages with different compression settings. This column was added in MySQL 5.7.8 with the introduction of the InnoDB transparent page compression feature. This column displays incorrect data after a server restart (Bug #78197) and is removed in 5.7.10. Use SHOW CREATE TABLE to view the current page compression setting."

At the same time, https://dev.mysql.com/doc/refman/5.7/en/innodb-page-compression.html still shows example where this column is selected, without any notes or references that it may not exist:

"# Query page compression metadata in INFORMATION_SCHEMA.INNODB_SYS_TABLESPACES
    
mysql> SELECT SPACE, NAME, FS_BLOCK_SIZE, FILE_SIZE, ALLOCATED_SIZE, COMPRESSION FROM 
INFORMATION_SCHEMA.INNODB_SYS_TABLESPACES WHERE NAME='employees/employees'\G
*************************** 1. row ***************************
SPACE: 45
NAME: employees/employees
FS_BLOCK_SIZE: 4096
FILE_SIZE: 23068672
ALLOCATED_SIZE: 19415040
COMPRESSION: Zlib"

How to repeat:
mysql> select version();
+-----------+
| version() |
+-----------+
| 5.7.14    |
+-----------+
1 row in set (0.00 sec)

mysql> SELECT * FROM  INFORMATION_SCHEMA.INNODB_SYS_TABLESPACES WHERE NAME='test/tpk2'\G
*************************** 1. row ***************************
         SPACE: 552
          NAME: test/tpk2
          FLAG: 33
   FILE_FORMAT: Barracuda
    ROW_FORMAT: Dynamic
     PAGE_SIZE: 16384
 ZIP_PAGE_SIZE: 0
    SPACE_TYPE: Single
 FS_BLOCK_SIZE: 4096
     FILE_SIZE: 138412032
ALLOCATED_SIZE: 43683840
1 row in set (0.00 sec)

mysql> SELECT SPACE, NAME, FS_BLOCK_SIZE, FILE_SIZE, ALLOCATED_SIZE, COMPRESSION FROM  INFORMATION_SCHEMA.INNODB_SYS_TABLESPACES WHERE NAME='text/tpk2';
ERROR 1054 (42S22): Unknown column 'COMPRESSION' in 'field list'

Suggested fix:
Make sure the manual is properly updated, everywhere, when you remove the feature or make incompatible change at GA stage. Start with fixing this specific case.
[25 Aug 2016 12:15] Valeriy Kravchuk
See http://bugs.mysql.com/bug.php?id=82462 also :)
[25 Aug 2016 13:22] MySQL Verification Team
Thank you for the bug report.
[8 Sep 2016 19:58] Daniel Price
Posted by developer:
 
The referenced documentation has been revised. The changes should appear online soon.
Thank you for the bug report.