instance method
current_database
Ruby on Rails 2.3.18
Since v2.2.3 Last seen in v3.2.22.5Signature
current_database()
Returns the current database name.
Source
# File activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb, line 681
def current_database
query('select current_database()')[0][0]
end
Defined in activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb line 681
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::ConnectionAdapters::PostgreSQLAdapter