Please install mysql adapter 'gem install activerecord-mysql-adapter'

前端 未结 16 1410
挽巷
挽巷 2020-12-28 12:23

I\'m having trouble finding a solution to this problem. I\'m getting the error:

Please install the mysql adapter: \'gem install activerecord-mysql-adapter\'
         


        
16条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2020-12-28 13:05

    In my case, when I also got this error:

    rake aborted! Please install the mysql adapter: gem install activerecord-mysql-adapter (mysql is not part of the bundle. Add it to Gemfile.)

    After I searched Google and tried many ways, it didn't work. Finally, the answer is

    • Navigate to the root of your app, run open gemfile
    • Add the line gem 'mysql2', '< 0.3.7' directly below the gem line for rails.

提交回复
热议问题