Apple MacBook Pro (Retina) connecting to a MySQL database
Posted: Tue Sep 09, 2014 3:08 pm
Hi guys I have moved off PC and onto Apple.
I have MySql and Navicat for MySQL on my Mac. I can open up my database with MySql with no problem.
I have taken the code off my PC and onto my MAC and cannot connect to my database through my local port. The error i get is:
"Unable to connect to database: Can't connect to local MySql server through socket '3306' (2)"
What should I change?
-- set up the connection parameters - edit these to suit your database
put "localhost" into tDatabaseAddress
put "plascondropanalysisdb" into tDatabaseName
put "root" into tDatabaseUser
put "" into tDatabasePassword
put "localhost" into tDatabaseAddress
put "plascondropanalysisdb" into tDatabaseName
-- connect to the database
put revOpenDatabase("MySQL", tDatabaseAddress, tDatabaseName, tDatabaseUser, tDatabasePassword,False,3306, 0, True) into tResult
I have MySql and Navicat for MySQL on my Mac. I can open up my database with MySql with no problem.
I have taken the code off my PC and onto my MAC and cannot connect to my database through my local port. The error i get is:
"Unable to connect to database: Can't connect to local MySql server through socket '3306' (2)"
What should I change?
-- set up the connection parameters - edit these to suit your database
put "localhost" into tDatabaseAddress
put "plascondropanalysisdb" into tDatabaseName
put "root" into tDatabaseUser
put "" into tDatabasePassword
put "localhost" into tDatabaseAddress
put "plascondropanalysisdb" into tDatabaseName
-- connect to the database
put revOpenDatabase("MySQL", tDatabaseAddress, tDatabaseName, tDatabaseUser, tDatabasePassword,False,3306, 0, True) into tResult