0

I 've re-installed mysql, uninstalled MAMP. So currently I should only have one version of mysql. I've done the following:

  1. Installed phpmyadmin
  2. Created a database

I try to import data to it, but the file is too big so I do it via the command line. But there I dont see my newly created database, furthermore I see less databases. If I do show databases; on the command it shows:

information_schema
test

It doesnt show my newly created Database and it doesn`t show other databases that were pre-installed, these are the databases that I see on phpmyadmin:

information_schema
mysql
performance_schema
test
myBBDD->the one I just created and I was looking for to import data via command-line

It seems I have two versions of mysql, but if I stop mysql via command line, I then can't access phpmyadmin so I guess it's the same one, but for some reason I can't access the same databases.

If you could throw me a bone on this? Im completely lost.

To install mysql and phpmyadmin I've followed this tutorial

[EDIT] I tried to delete test and it did dissapear from the command-line too, so it is the same version of MySql, so it must be a permission issue... still investigating

Thanks.

subharb
  • 3,374
  • 8
  • 41
  • 72

2 Answers2

0

Sounds like you have MAMP's version of MySQL and a standalone MySQL. See this answer: Access MAMP's MySQL from Terminal

Community
  • 1
  • 1
Grasshopper
  • 152
  • 1
  • 10
  • What user are you logging into phpmyadmin with and what user are using when you login via command line? Make sure the command line user has permissions to the databases and isn't anonymous. – Grasshopper Nov 11 '14 at 21:42
0

Just had the same issue, in my case it turned out to be that I wasn't logging in as the correct user.

In the command line, instead of running just mysql, try running mysql -u root -p (replace "root" with whatever user you used in phpMyAdmin to set the databases up). You should then be able to type in the password. Check show databases; again.

Just noticed that user Grasshopper in a previous answers' comments was suggesting exactly this, hopefully this will help someone anyway by spelling it out.

Dominic Hurr
  • 301
  • 2
  • 5