Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Oracle adapter removes double quotes when quoting table and column names

  • Loading branch information...
commit db41b634f090a64b20208a804cc8812a878c541d 1 parent cb25537
@rsim rsim authored
Showing with 7 additions and 1 deletion.
  1. +7 −1 activerecord/test/cases/base_test.rb
View
8 activerecord/test/cases/base_test.rb
@@ -70,7 +70,13 @@ def test_column_names_are_escaped
}
quoted = conn.quote_column_name "foo#{badchar}bar"
- assert_equal("#{badchar}foo#{badchar * 2}bar#{badchar}", quoted)
+ if current_adapter?(:OracleAdapter)
+ # Oracle does not allow double quotes in table and column names at all
+ # therefore quoting removes them
+ assert_equal("#{badchar}foobar#{badchar}", quoted)
+ else
+ assert_equal("#{badchar}foo#{badchar * 2}bar#{badchar}", quoted)
+ end
end
def test_columns_should_obey_set_primary_key
Please sign in to comment.
Something went wrong with that request. Please try again.