From c2d0a3dac4baf9561a4ef8e8498674399310cfea Mon Sep 17 00:00:00 2001 From: Lionel Laffineur Date: Sun, 5 Nov 2023 16:16:56 +0100 Subject: [PATCH] Remove size for integer on MySQL 8+ --- adminer/include/editing.inc.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/adminer/include/editing.inc.php b/adminer/include/editing.inc.php index 5e12d44b..87b109c3 100644 --- a/adminer/include/editing.inc.php +++ b/adminer/include/editing.inc.php @@ -208,6 +208,9 @@ function process_length($length) { */ function process_type($field, $collate = "COLLATE") { global $unsigned; + if (DRIVER === 'server' && ($field['unsigned'] === 'unsigned' || stripos( (string) $field['type'],'int') !== false) && min_version(8)) { + $field["length"] = ''; + } return " $field[type]" . process_length($field["length"]) . (preg_match(number_type(), $field["type"]) && in_array($field["unsigned"], $unsigned) ? " $field[unsigned]" : "")