diff options
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb index 7ff3b755fd..3ced32e42d 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb @@ -24,7 +24,7 @@ module ActiveRecord # table_exists?(:developers) def table_exists?(table_name) begin - select_value("SELECT 1 FROM #{table_name.to_s} where 1=0") + select_value("SELECT 1 FROM #{quote_table_name(table_name)} where 1=0") true rescue false |