Module: Listable::ConnectionAdapters::PostgreSQLExtensions

Includes:
ConcatenationMethods::PipeOperator
Defined in:
lib/listable/connection_adapters.rb

Instance Method Summary collapse

Methods included from ConcatenationMethods::PipeOperator

#concat

Instance Method Details

#viewsObject



41
42
43
44
45
46
47
# File 'lib/listable/connection_adapters.rb', line 41

def views
  query(<<-SQL, 'SCHEMA').map { |row| row[0] }
    SELECT table_name
    FROM INFORMATION_SCHEMA.views
    WHERE table_schema = ANY (current_schemas(false))
  SQL
end