This example illustrates how to alter user table.
In this example we alter user table in which add a column by query "ALTER TABLE user ADD COLUMN userid INT". In the first table we can see there is only three column but after the alteration in the next table we can see there is four column.
Query
CREATE USER 'user'@'localhost' IDENTIFIED BY '1234556978';
Query
GRANT SELECT,INSERT,UPDATE,DELETE ON *.* TO 'user'@'localhost';
Query
show grants for user@localhost;
Output
+---------------------------------------------------------------------------------------------------------------------
-----------------+
| Grants for user@localhost
|
+---------------------------------------------------------------------------------------------------------------------
-----------------+
| GRANT SELECT, INSERT, UPDATE, DELETE ON *.* TO 'user'@'localhost' IDENTIFIED BY PASSWORD '*C59B95112565D0CB68F9AAB8E
48ABA4790367F48' |
+---------------------------------------------------------------------------------------------------------------------
-----------------+
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.