Blog (or) Scribble Pad

Solution to "The bundled mysql.rb driver has been removed from Rails 2.2. Please install the mysql gem and try again: gem install mysql. rake aborted! no such file to load -- mysql/mysql_api"

I tried installing Fedena this evening. While going through the fifth step i,e executing the command

rake db:create

on my command prompt I ended up with this error message "!!! The bundled mysql.rb driver has been removed from Rails 2.2. Please install the mysql gem and try again: gem install mysql. rake aborted! no such file to load -- mysql/mysql_api". I tried a lot of websites for a solution and ended up smoking three cigarettes in a row and of course with no solution.

Then after an episode of 'House of cards', I again checked back the error and tried the command

gem install mysql

which I did tried three or four times before but neglected the description it gave me. It said the mysql connector was installed successfully but the version might change so get the libmysql.dll from the location it downloaded (for me it is, http://cdn.mysql.com/Downloads/Connector-C/mysql-connector-c-noinstall-6.0.2-win32.zip) the connector into C:\ruby\bin (bin folder in your ruby installation).

Then reluctantly I copied the above url and downloaded the zip file. From the zip I extracted the libmysql.dll (\lib\libmysql.dll) file into the config folder in Fedena directory and replaced the already existing file. That's it. Then the command

rake db:create
worked smoothly and I continued installing Fedena successfully.