0

I previously had a version of MYSQL on my old hard drive but the hard drive stopped working properly so I now use an external hard drive as my start up hard drive. This new hard drive does not have any version of mysql as far as I can tell.

I am currently working on a project using Codeigniter. When I go to the terminal on my Mac and type 'mysql', it says it cannot be found. I also don't have the MYSQL Preference pane in my system preferences so im quite sure its not installed. Mysql workbench doesnt work either cause theres no MYSQL. But for the current project I am working on, i have a specific database specified and I expected it not to be able to get any data since I dont have MYSQL on my computer but that's not the case. The database connects and it seems to work fine. There's even also rows and tables in the database I specified (The database is the same as the one I was using on my previous hard drive before it stopped working, so i guess that's where the data may be coming from but I dont know how). I have no way of accessing the data in the database though since I can't connect from my terminal or MYSQL Workbench. Does anyone have any ideas on how I can fix this?

1 Answers1

0

check appication/config/database.php to make sure you are connecting to which database

this will answer your questions

it may be issue with terminal. Set Environment Variable for reference see this 'link'

Null Pointer
  • 458
  • 1
  • 4
  • 14
  • I know the database I am connected to, but I just cant access it via the terminal or mYSQL workbench cause it keeps saying mysql is not found – Arthur Bello May 31 '18 at 11:56
  • I see where the problem is, my terminal was pointing to a location where mysql doesn't exist. I also found another version of mysql on my mac with MAMP but that doesnt look like the one codeigniter is using. Do you know of anyone for me to change the specific mysql that codeigniter uses (not the database, but the mysql server) – Arthur Bello May 31 '18 at 12:27