datamapper / dm-migrations

DataMapper plugin for writing and speccing migrations
http://datamapper.org/
MIT License
66 stars 42 forks source link

NoMethodError: undefined method `variable_value' (JRuby 1.6.3 and dm-mysql-adapter) #29

Open kyledrake opened 13 years ago

kyledrake commented 13 years ago

This was resolved once and came back: http://datamapper.lighthouseapp.com/projects/20609/tickets/1410-dm-migrations-dm-mysql-adapter-undefined-method

This monkey patch still fixes the problem:

      repository.adapter.class.class_eval do
        def show_variable(name)
          select('SELECT variable_value FROM information_schema.session_variables WHERE LOWER(variable_name) = ?', name).first
        end
      end