Mysql ERROR : not connected
The first step is that you need to check if you are in the MYSQL Shell SQL mode or JS mode.
Then if you are in SQL mode then you are good to go else you need to switch to SQL mode by this command
The next step is to connect using this command
In your case, you might have given the privilege as the IP address so you need to check your localhost IP which can be done by this command in your command prompt.
ipconfig and then just check the IP address and put it in place of localhost in the previous command. If this still doesn't works then put
After this, it will prompt to add or save the password , enter a unique password there.
After this you are good to go and check the user and localhost after this by this command
SELECT user, host FROM mysql.user;