method

insert_versions_sql

Importance_0
v7.1.3.2 - Show latest stable - 0 notes - Class: ActiveRecord::ConnectionAdapters::SchemaStatements
insert_versions_sql(versions) private

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb, line 1837
        def insert_versions_sql(versions)
          sm_table = quote_table_name(schema_migration.table_name)

          if versions.is_a?(Array)
            sql = +"INSERT INTO #{sm_table} (version) VALUES\n"
            sql << versions.reverse.map { |v| "(#{quote(v)})" }.join(",\n")
            sql << ";"
            sql
          else
            "INSERT INTO #{sm_table} (version) VALUES (#{quote(versions)});"
          end
        end
Register or log in to add new notes.