mysql client doesn't see mysql database

Problems with the Windows version of XAMPP, questions, comments, and anything related.

mysql client doesn't see mysql database

Postby pittore44 » 11. September 2011 09:29

after recent xampp installation and configuration, mysqladmin shows the msql database and its tables but when I switch to the mysql client (I use cmd in the RUN pop up to bring up the command window). I change to the c:\xampp\mysql\bin directory and enter mysql to get the mysql> (the prompt) but when I type show databases; the mysql database doesn't appear and when I type use mysql I get a 1044 error, access denied.

Why should these two interfaces to the same mysql product give such different results?

I also have the same problem regarding updating root password for mysql database using mysqladmin. If I leave user as default (root) but change the password, then CD collection stops working, unless I change the password back to empty string.

There seems to be a serious disconnect between different elements of the overall software configuration.
pittore44
 
Posts: 2
Joined: 11. September 2011 09:14

Re: mysql client doesn't see mysql database

Postby Altrea » 11. September 2011 14:01

If you want to use the mysql cli, you have to log in with /u /p parameter for user and password.

If you change the password for root user, change that user in the webpallications too.
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 6946
Joined: 17. August 2009 13:05
XAMPP Version: 5.5.19
Operating System: Windows 10 Pro x64

Re: mysql client doesn't see mysql database

Postby pittore44 » 11. September 2011 17:14

that worked, thanks!

I logged into mysql using mysql -u root -p

It prompted me for the password and I just hit enter to use the idea that there is no password for root

When I type in show databases; it now shows the mysql database

I am wondering if I should fix the security gap by changing the password from nothing to something?

If I do that, is there a way to make the CD Collections example still work? I am concerned about this, because I want to study the code for this example, because it is close to something I want to attempt.
pittore44
 
Posts: 2
Joined: 11. September 2011 09:14

Re: mysql client doesn't see mysql database

Postby Altrea » 11. September 2011 21:32

pittore44 wrote:I am wondering if I should fix the security gap by changing the password from nothing to something?

It is no security gap, if you use XAMPP for what it is produced: A local development environment with no connection to the internet or big networks.

pittore44 wrote:If I do that, is there a way to make the CD Collections example still work? I am concerned about this, because I want to study the code for this example, because it is close to something I want to attempt.

Sure, there is always a way.
The sourcecode for that example is in your \xampp\htdocs\xampp\cds.php file.
The place where to put the password is in lines 4 and 64 where the mysql connection is established.
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 6946
Joined: 17. August 2009 13:05
XAMPP Version: 5.5.19
Operating System: Windows 10 Pro x64


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 35 guests