method

enable_extension

Importance_0
Ruby on Rails latest stable (v7.1.3.2) - 0 notes - Class: ActiveRecord::ConnectionAdapters::PostgreSQLAdapter
enable_extension(name, **) public

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/postgresql_adapter.rb, line 470
      def enable_extension(name, **)
        schema, name = name.to_s.split(".").values_at(-2, -1)
        sql = +"CREATE EXTENSION IF NOT EXISTS \"#{name}\""
        sql << " SCHEMA #{schema}" if schema

        internal_exec_query(sql).tap { reload_type_map }
      end
Register or log in to add new notes.