instance method
extensions
Ruby on Rails 8.0.4
Since v4.0.13Signature
extensions()
No documentation comment.
Source
# File activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb, line 501
def extensions
query = <<~SQL
SELECT
pg_extension.extname,
n.nspname AS schema
FROM pg_extension
JOIN pg_namespace n ON pg_extension.extnamespace = n.oid
SQL
internal_exec_query(query, "SCHEMA", allow_retry: true, materialize_transactions: false).cast_values.map do |row|
name, schema = row[0], row[1]
schema = nil if schema == current_schema
[schema, name].compact.join(".")
end
end
Defined in activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb line 501
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::ConnectionAdapters::PostgreSQLAdapter