Paste this into a new question or an answer at dba.stackexchange.com:
<!-- --> > CREATE TABLE tab(i INT); > > > > > <pre> > ✓ > </pre> <!-- --> > INSERT INTO tab VALUES (10); > > <pre> > ✓ > </pre> <!-- --> > SELECT * FROM tab; > > <pre> > | i | > | -: | > | 10 | > </pre> <!-- --> > ALTER TABLE tab RENAME column i TO x; > > <pre> > ✓ > </pre> <!-- --> > SELECT * > FROM tab; > > <pre> > | x | > | -: | > | 10 | > </pre> *db<>fiddle [here](https://dbfiddle.uk/?rdbms=mysql_8.0&fiddle=dc21e8c179aa5325d9f337c54cb0e63f)*
back to fiddle