diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2017-04-20 18:08:08 -0400 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2017-04-20 18:08:08 -0400 |
commit | 972df059bbedfe60d29caa8a561f5aff76883e63 (patch) | |
tree | 60d9000e2709e688250abef2ed4e0460a268c0bf /activerecord/lib/active_record | |
parent | e88636f733ad81c10dffde2e084e77034bc920fe (diff) | |
parent | 2d699e24ff10158c0831cf6b7f5e5b12ac41903a (diff) | |
download | rails-972df059bbedfe60d29caa8a561f5aff76883e63.tar.gz rails-972df059bbedfe60d29caa8a561f5aff76883e63.tar.bz2 rails-972df059bbedfe60d29caa8a561f5aff76883e63.zip |
Merge pull request #28681 from runephilosof/fix-mysql-grant
Fix quoting in db:create grant all statement.
Diffstat (limited to 'activerecord/lib/active_record')
-rw-r--r-- | activerecord/lib/active_record/tasks/mysql_database_tasks.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/tasks/mysql_database_tasks.rb b/activerecord/lib/active_record/tasks/mysql_database_tasks.rb index 920830b9cf..c05f0a8fbb 100644 --- a/activerecord/lib/active_record/tasks/mysql_database_tasks.rb +++ b/activerecord/lib/active_record/tasks/mysql_database_tasks.rb @@ -104,7 +104,7 @@ module ActiveRecord def grant_statement <<-SQL -GRANT ALL PRIVILEGES ON #{configuration['database']}.* +GRANT ALL PRIVILEGES ON `#{configuration['database']}`.* TO '#{configuration['username']}'@'localhost' IDENTIFIED BY '#{configuration['password']}' WITH GRANT OPTION; SQL |