I am just getting started with PHP & MYSQL. I have had MAMP installed for quite a while and have used it to dabble in local development mostly with Wordpress.
Following along with the instructions in the book "Build Your Own Database Driven Web Site Using PHP & MySQL”; I installed MySQL Server. All the terminal commands were reacting as set out in the book.
But… I am now trying to connect to the MySQL server using the command:
mysql -u root -p
I enter my password and I keep getting the following error:
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
I even went ahead and changed my password (via MAMP) but still no joy.
I am getting the feeling that there might be some kind of conflict between the MAMP program and the newly installed MySQL Server program but I have no idea how to sort this out.
As you can imagine, I am hyped to get started with the coding/programming (:
Welcome to the MySQL monitor. Commands end with ; or \\g.
Your MySQL connection id is 9
Server version: 5.1.37 Source distribution
Type 'help;' or '\\h' for help. Type '\\c' to clear the current input statement.
mysql>
I guess that I had to use the ‘path’ to mysql in MAMP
Eitherway, I am in so I can continue with the book Yay!!
BTW, @ feketegy, I checked out Sequel Pro. That is a very useful bit of kit! It will defo come in handy later on but I really want to nail this Terminal command bit.
Anyway, thanks for replying (thanks for your help)