Class: Rails::DataMapper::Storage::Mysql
- Inherits:
-
Rails::DataMapper::Storage
- Object
- Rails::DataMapper::Storage
- Rails::DataMapper::Storage::Mysql
- Defined in:
- lib/dm-rails/storage.rb
Instance Attribute Summary
Attributes inherited from Rails::DataMapper::Storage
Instance Method Summary collapse
Methods inherited from Rails::DataMapper::Storage
#charset, #create, create_all, create_environment, #create_message, #database, #drop, drop_all, drop_environment, #drop_message, #initialize, new, #password, #username
Constructor Details
This class inherits a constructor from Rails::DataMapper::Storage
Instance Method Details
#_create ⇒ Object
159 160 161 |
# File 'lib/dm-rails/storage.rb', line 159 def _create execute("CREATE DATABASE `#{database}` DEFAULT CHARACTER SET #{charset} DEFAULT COLLATE #{collation}") end |
#_drop ⇒ Object
163 164 165 |
# File 'lib/dm-rails/storage.rb', line 163 def _drop execute("DROP DATABASE IF EXISTS `#{database}`") end |