class PostgreSQLAdapter
Ruby on Rails 3.2.22.5
Since v2.2.3The PostgreSQL adapter works both with the native C (ruby.scripting.ca/postgres/) and the pure Ruby (available both as gem and from rubyforge.org/frs/?group_id=234&release_id=1944) drivers.
Options:
-
:host- Defaults to “localhost”. -
:port- Defaults to 5432. -
:username- Defaults to nothing. -
:password- Defaults to nothing. -
:database- The name of the database. No default, must be provided. -
:schema_search_path- An optional schema search path for the connection given as a string of comma-separated schema names. This is backward-compatible with the:schema_orderoption. -
:encoding- An optional client encoding that is used in aSET client_encoding TO <encoding>call on the connection. -
:min_messages- An optional client min messages that is used in aSET client_min_messages TO <min_messages>call on the connection.
Inherits from
Namespace
Modules
Classes
Constants
- ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::ADAPTER_NAME
- ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::BYTEA_COLUMN_TYPE_OID
- ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::FEATURE_NOT_SUPPORTED
- ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::FOREIGN_KEY_VIOLATION
- ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::MONEY_COLUMN_TYPE_OID
- ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::NATIVE_DATABASE_TYPES
- ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::UNIQUE_VIOLATION
Methods (defined here)
- # active?
- # adapter_name
- # add_column
- # begin_db_transaction
- # change_column
- # change_column_default
- # change_column_null
- # clear_cache!
- # client_min_messages
- # client_min_messages=
- # columns
- # commit_db_transaction
- # create_database
- # create_savepoint
- # current_database
- # current_schema
- # disconnect!
- # encoding
- # escape_bytea
- # exec_delete
- # exec_query
- # exec_update
- # execute
- # explain
- # indexes
- # index_name_length
- # insert_sql
- # outside_transaction?
- # postgresql_version
- # primary_key
- # quote_table_name
- # reconnect!
- # release_savepoint
- # rename_column
- # rename_index
- # rename_table
- # reset!
- # rollback_db_transaction
- # rollback_to_savepoint
- # schema_exists?
- # schema_search_path
- # schema_search_path=
- # select_rows
- # serial_sequence
- # session_auth=
- # set_standard_conforming_strings
- # sql_for_insert
- # substitute_at
- # supports_ddl_transactions?
- # supports_explain?
- # supports_index_sort_order?
- # supports_insert_with_returning?
- # supports_migrations?
- # supports_savepoints?
- # supports_statement_cache?
- # table_alias_length
- # table_exists?
- # tables
- # translate_exception
- # type_cast
- # type_to_sql
- # unescape_bytea
- # update_sql
- self. new
Private methods
(11)
Implementation detail — not part of the public API.
Methods (inherited)
From ActiveRecord::ConnectionAdapters::AbstractAdapter (35)
- # active?
- # adapter_name
- # case_insensitive_comparison
- # case_sensitive_modifier
- # clear_cache!
- # close
- # create_savepoint
- # current_savepoint_name
- # decrement_open_transactions
- # disable_referential_integrity
- # disconnect!
- # expire
- # increment_open_transactions
- # lease
- # log
- # prefetch_primary_key?
- # quote_table_name
- # raw_connection
- # reconnect!
- # release_savepoint
- # requires_reloading?
- # reset!
- # rollback_to_savepoint
- # substitute_at
- # supports_bulk_alter?
- # supports_count_distinct?
- # supports_ddl_transactions?
- # supports_explain?
- # supports_index_sort_order?
- # supports_migrations?
- # supports_primary_key?
- # supports_savepoints?
- # transaction_joinable=
- # translate_exception
- # verify!
From ActiveRecord::ConnectionAdapters::QueryCache (8)
- # cache
- # clear_query_cache
- # disable_query_cache!
- # enable_query_cache!
- # select_all
- # uncached
- self. dirties_query_cache
- self. included
From ActiveSupport::Callbacks (1)
From Object (18)
- # acts_like?
- # blank?
- # create_fixtures
- # duplicable?
- # html_safe?
- # in?
- # instance_variable_names
- # options
- # presence
- # present?
- # test_homepage
- # to_json
- # to_param
- # to_query
- # try
- # unescape
- # with_options
- self. table_name_prefix
From ActiveSupport::Concern (3)
- # append_features
- # included
- self. extended
From ActiveSupport::DescendantsTracker (6)
- # descendants
- # direct_descendants
- # inherited
- self. clear
- self. descendants
- self. direct_descendants