26.4.5.20 The version_major() Function
This function returns the major version of the MySQL server.
It was added in MySQL 5.7.9.
A TINYINT UNSIGNED
value.
mysql> SELECT VERSION(), sys.version_major();
+------------------+---------------------+
| VERSION() | sys.version_major() |
+------------------+---------------------+
| 5.7.24-debug-log | 5 |
+------------------+---------------------+