0

I am facing this error every time I create a database in CLI interface of mysql:

Image of error

I am using Xampp

Halvor Holsten Strand
  • 19,829
  • 17
  • 83
  • 99
MAO
  • 81
  • 9

2 Answers2

1

You may need to set up a root account for your MySQL database:

In the terminal type:

mysqladmin -u root password 'root password goes here'

And then to invoke the MySQL client:

mysql -h localhost -u root -p

more reference Reference

Community
  • 1
  • 1
Chetan Naik
  • 151
  • 13
1

A simple and 100% working solution for this problem is:
Install Xampp outside the C: Folder and it will definitely work for you, without any permission problems ever.
But remember to provide xampp-control.exe administrative privileges always to terminate any port problems.

Kartik Arora
  • 958
  • 1
  • 10
  • 17
  • a perfect and esay solution – Avinash jain Jul 19 '18 at 17:27
  • @Avinashjain Thanks buddy. – Kartik Arora Jul 19 '18 at 17:28
  • Outside of the C: folder? What do you mean? I have XAMPP in its own folder: xampp (though directly under C:\). So you're saying to install the xampp folder into something like C:\Users\Me? I tried that once and got different permissions issues, strangely. Where do you install it? I'm not comfortable running XAMPP with admin privileges because I don't know exactly what it could ever do using those privileges... see what I mean? It's a security concern. Most other apps I use don't require that. – SteveExdia Nov 08 '22 at 19:02