バージョンごとのドキュメント一覧

20.11. クライアント接続デフォルト #

<title>Client Connection Defaults</title>

20.11.1. 文の動作 #

<title>Statement Behavior</title>
client_min_messages (enum) #

Controls which <link linkend="runtime-config-severity-levels">message levels</link> are sent to the client. Valid values are <literal>DEBUG5</literal>, <literal>DEBUG4</literal>, <literal>DEBUG3</literal>, <literal>DEBUG2</literal>, <literal>DEBUG1</literal>, <literal>LOG</literal>, <literal>NOTICE</literal>, <literal>WARNING</literal>, and <literal>ERROR</literal>. Each level includes all the levels that follow it. The later the level, the fewer messages are sent. The default is <literal>NOTICE</literal>. Note that <literal>LOG</literal> has a different rank here than in <xref linkend="guc-log-min-messages"/>. どのメッセージレベルをクライアントに送るかを管理します。有効な値は、DEBUG5DEBUG4DEBUG3DEBUG2DEBUG1LOGNOTICEWARNINGおよびERRORです。 それぞれのレベルはそれに続く全てのレベルを包含します。 レベルが後の方になるにつれ、より少ないメッセージが送られます。 デフォルトはNOTICEです。 ここでのLOGの優先順位がlog_min_messagesの場合と異なることに注意してください。

<literal>INFO</literal> level messages are always sent to the client. INFOレベルのメッセージは常にクライアントに送られます。

search_path (string) #

This variable specifies the order in which schemas are searched when an object (table, data type, function, etc.) is referenced by a simple name with no schema specified. When there are objects of identical names in different schemas, the one found first in the search path is used. An object that is not in any of the schemas in the search path can only be referenced by specifying its containing schema with a qualified (dotted) name. この変数は、オブジェクト(テーブル、データ型、関数など)がスキーマを指定されていない単純な名前で参照されている場合に、スキーマを検索する順番を指定します。 異なるスキーマに同じ名前のオブジェクトがある場合、検索パスで最初に見つかったものが使用されます。 検索パス内のどのスキーマにも存在しないオブジェクトを参照するには、修飾名(ドット付き)でそのオブジェクトが含まれるスキーマを指定する必要があります。

The value for <varname>search_path</varname> must be a comma-separated list of schema names. Any name that is not an existing schema, or is a schema for which the user does not have <literal>USAGE</literal> permission, is silently ignored. search_pathの値は、スキーマの名前をカンマで区切った一覧でなければなりません。 存在していないスキーマ、またはユーザがUSAGE権限を所有していないスキーマは警告なしに無視されます。

If one of the list items is the special name <literal>$user</literal>, then the schema having the name returned by <function>CURRENT_USER</function> is substituted, if there is such a schema and the user has <literal>USAGE</literal> permission for it. (If not, <literal>$user</literal> is ignored.) もしそのようなスキーマが存在し、ユーザがそれにたいしてUSAGE権限を所有している場合、一覧内の項目の1つが特別な名前である$userの場合、CURRENT_USERと同じ名前を持つスキーマがあれば、そのスキーマが置換されます。 (このような名前空間がない場合は$userは無視されます。)

The system catalog schema, <literal>pg_catalog</literal>, is always searched, whether it is mentioned in the path or not. If it is mentioned in the path then it will be searched in the specified order. If <literal>pg_catalog</literal> is not in the path then it will be searched <emphasis>before</emphasis> searching any of the path items. システムカタログのスキーマであるpg_catalogは、パスでの指定の有無にかかわらず、常に検索されます。 パスで指定されている場合は、指定された順序で検索されます。 pg_catalogがパスに含まれていない場合、パスに含まれる項目を検索する前に検索が行われます

To further split hairs, funcname('foo') does not use the temporary schema, even when it considers typname='funcname'. This paragraph refers to function names in a loose sense, "pg_proc.proname or func_name grammar production". 細かい話ですが、typnameが'funcname'である場合でも、funcname('foo')は一時スキーマを使いません。 この段落では、関数名とは「pg_proc.pronameあるいは文法生成物のfunc_name」のどちらでも良いという意味で使用しています。

Likewise, the current session's temporary-table schema, <literal>pg_temp_<replaceable>nnn</replaceable></literal>, is always searched if it exists. It can be explicitly listed in the path by using the alias <literal>pg_temp</literal><indexterm><primary>pg_temp</primary></indexterm>. If it is not listed in the path then it is searched first (even before <literal>pg_catalog</literal>). However, the temporary schema is only searched for relation (table, view, sequence, etc.) and data type names. It is never searched for function or operator names. 同様に、現在のセッションの一時テーブルスキーマpg_temp_nnnも、存在すれば常に検索されます。 これはpg_tempという別名を使用してパスに明示的に列挙させることができます。 パスに列挙されていない場合、最初に(pg_catalogよりも前であっても)検索されます。 しかし、一時スキーマはリレーション(テーブル、ビュー、シーケンスなど)とデータ型名に対してのみ検索されます。 関数や演算子名に対してはまったく検索されません。

When objects are created without specifying a particular target schema, they will be placed in the first valid schema named in <varname>search_path</varname>. An error is reported if the search path is empty. 対象となる特定のスキーマを指定せずにオブジェクトが作成された場合、それらのオブジェクトはsearch_pathで名前を付けられた最初に有効となっているスキーマに配置されます。 検索パスが空の場合、エラーが報告されます。

The default value for this parameter is <literal>"$user", public</literal>. This setting supports shared use of a database (where no users have private schemas, and all share use of <literal>public</literal>), private per-user schemas, and combinations of these. Other effects can be obtained by altering the default search path setting, either globally or per-user. このパラメータのデフォルト値は"$user", publicです。 この設定はデータベースの共有(どのユーザも非公開のスキーマを持たず、全員がpublicを共有)、ユーザごとの非公開のスキーマ、およびこれらの組み合わせがサポートします。 デフォルトの検索パスの設定を全体的またはユーザごとに変更することで、その他の効果を得ることもできます。

For more information on schema handling, see <xref linkend="ddl-schemas"/>. In particular, the default configuration is suitable only when the database has a single user or a few mutually-trusting users. スキーマの扱いについての詳細は、5.9をご覧ください。 とりわけ、デフォルトの設定はデータベースのユーザが、一人あるいはお互いに信頼できる少数のユーザだけである場合にのみ適切です。

The current effective value of the search path can be examined via the <acronym>SQL</acronym> function <function>current_schemas</function> (see <xref linkend="functions-info"/>). This is not quite the same as examining the value of <varname>search_path</varname>, since <function>current_schemas</function> shows how the items appearing in <varname>search_path</varname> were resolved. SQL関数のcurrent_schemas によって、検索パスの現在の有効な値を調べることができます(9.26を参照してください)。 これは、search_path の値を調べるのとは異なります。 current_schemasは、search_pathに現れる項目がどのように解決されたかを表すからです。

row_security (boolean) #

This variable controls whether to raise an error in lieu of applying a row security policy. When set to <literal>on</literal>, policies apply normally. When set to <literal>off</literal>, queries fail which would otherwise apply at least one policy. The default is <literal>on</literal>. Change to <literal>off</literal> where limited row visibility could cause incorrect results; for example, <application>pg_dump</application> makes that change by default. This variable has no effect on roles which bypass every row security policy, to wit, superusers and roles with the <literal>BYPASSRLS</literal> attribute. この設定値は、行セキュリティポリシーの適用によってエラーを生じさせるかどうかを制御します。 onに設定すると、通常通りポリシーが適用されます。 offにすると、少なくともひとつのポリシーが適用されたクエリは失敗します。 デフォルトはonです。 行の可視性が制限されている場合、offにすると不正な結果を招くことがあります。 たとえば、pg_dumpはデフォルトでoffにしています。 この設定値は、行セキュリティポリシーを迂回するロールには効果がありません。 それはすなわち、BYPASSRLSアトリビュートを持つスーパーユーザです。

For more information on row security policies, see <xref linkend="sql-createpolicy"/>. 行セキュリティポリシーについての更なる情報はCREATE POLICYをご覧ください。

default_table_access_method (string) #

This parameter specifies the default table access method to use when creating tables or materialized views if the <command>CREATE</command> command does not explicitly specify an access method, or when <command>SELECT ... INTO</command> is used, which does not allow specifying a table access method. The default is <literal>heap</literal>. このパラメータは、テーブルあるいはマテリアライズドビューの作成時にCREATEコマンドが明示的にアクセスメソッドを指定しないか、あるいはテーブルアクセスメソッドを指定できないSELECT ... INTOが利用された時に使われるデフォルトのテーブルアクセスメソッドを指定します。 デフォルトはheapです。

default_tablespace (string) #

This variable specifies the default tablespace in which to create objects (tables and indexes) when a <command>CREATE</command> command does not explicitly specify a tablespace. この変数は、CREATEコマンドで明示的にテーブル空間を指定していない場合にオブジェクトの作成先となるデフォルトのテーブル空間を指定します。

The value is either the name of a tablespace, or an empty string to specify using the default tablespace of the current database. If the value does not match the name of any existing tablespace, <productname>PostgreSQL</productname> will automatically use the default tablespace of the current database. If a nondefault tablespace is specified, the user must have <literal>CREATE</literal> privilege for it, or creation attempts will fail. 値はテーブル空間名、もしくは現在のデータベースのデフォルトのテーブル空間を使用することを意味する空文字列です。 この値が既存のテーブル空間名と一致しない場合、PostgreSQLは自動的に現在のデータベースのデフォルトのテーブル空間を使用します。 デフォルト以外のテーブル空間が指定された場合、ユーザはそのテーブル空間でCREATE権限を持たなければなりません。 さもなくば作成に失敗します。

This variable is not used for temporary tables; for them, <xref linkend="guc-temp-tablespaces"/> is consulted instead. この変数は一時テーブル向けには使用されません。 一時テーブル向けには代わりにtemp_tablespacesが考慮されます。

This variable is also not used when creating databases. By default, a new database inherits its tablespace setting from the template database it is copied from. また、この変数はデータベース作成時には使用されません。 デフォルトでは、新しいデータベースはコピー元のテンプレートデータベースからテーブル空間の設定を引き継ぎます。

If this parameter is set to a value other than the empty string when a partitioned table is created, the partitioned table's tablespace will be set to that value, which will be used as the default tablespace for partitions created in the future, even if <varname>default_tablespace</varname> has changed since then. パーティションテーブルが作られたときにこのパラメータが空文字以外に設定されていると、default_tablespaceがその後変更されたとしても、パーティションテーブルのテープル空間はその値になり、今後作られるパーティションのデフォルトテーブル空間として使われます。

For more information on tablespaces, see <xref linkend="manage-ag-tablespaces"/>. テーブル空間に付いてより詳細な情報は23.6を参照してください。

default_toast_compression (enum) #

This variable sets the default <link linkend="storage-toast">TOAST</link> compression method for values of compressible columns. (This can be overridden for individual columns by setting the <literal>COMPRESSION</literal> column option in <command>CREATE TABLE</command> or <command>ALTER TABLE</command>.) The supported compression methods are <literal>pglz</literal> and (if <productname>PostgreSQL</productname> was compiled with <option>&#45;-with-lz4</option>) <literal>lz4</literal>. The default is <literal>pglz</literal>. この変数は圧縮可能な列の値のデフォルトTOAST圧縮方式を設定します。 (これはCREATE TABLEあるいはALTER TABLECOMPRESSION列オプションを設定することにより、置き換えることができます。) サポートされている圧縮方式は、pglzlz4PostgreSQL--with-lz4でコンパイルされている場合)です。 デフォルトはpglzです。

temp_tablespaces (string) #

This variable specifies tablespaces in which to create temporary objects (temp tables and indexes on temp tables) when a <command>CREATE</command> command does not explicitly specify a tablespace. Temporary files for purposes such as sorting large data sets are also created in these tablespaces. この変数は、CREATEコマンドで明示的にテーブル空間が指定されない場合に、生成する一時オブジェクト(一時テーブルと一時テーブル上のインデックス)を格納するテーブル空間(複数可)を指定します。 大規模データ集合のソートなどを目的とした一時ファイルもまた、このテーブル空間(複数可)に作成されます。

The value is a list of names of tablespaces. When there is more than one name in the list, <productname>PostgreSQL</productname> chooses a random member of the list each time a temporary object is to be created; except that within a transaction, successively created temporary objects are placed in successive tablespaces from the list. If the selected element of the list is an empty string, <productname>PostgreSQL</productname> will automatically use the default tablespace of the current database instead. この値はテーブル空間名のリストです。 リストに複数の名前が存在する場合、一時オブジェクトが作成される度にPostgreSQLは無作為にリストから要素を選択します。 トランザクションの内側は例外で、連続して作成される一時オブジェクトはそのリストで連続するテーブル空間に格納されます。 リスト内の選択された要素が空文字列だった場合、PostgreSQLは自動的に現在のデータベースのデフォルトのテーブル空間を代わりに使用します。

When <varname>temp_tablespaces</varname> is set interactively, specifying a nonexistent tablespace is an error, as is specifying a tablespace for which the user does not have <literal>CREATE</literal> privilege. However, when using a previously set value, nonexistent tablespaces are ignored, as are tablespaces for which the user lacks <literal>CREATE</literal> privilege. In particular, this rule applies when using a value set in <filename>postgresql.conf</filename>. temp_tablespacesを対話式に設定する場合、存在しないテーブル空間を指定するとエラーになります。 ユーザがCREATE権限を持たないテーブル空間を指定した場合も同様です。 しかし事前に設定された値を使用する場合、存在しないテーブル空間は無視されます。 ユーザがCREATE権限を持たないテーブル空間も同様です。 具体的には、この規則はpostgresql.conf内で設定した値を使用する場合に適用されます。

The default value is an empty string, which results in all temporary objects being created in the default tablespace of the current database. デフォルト値は空文字列です。 この結果、すべての一時オブジェクトは現在のデータベースのデフォルトのテーブル空間内に作成されます。

See also <xref linkend="guc-default-tablespace"/>. default_tablespaceも参照してください

check_function_bodies (boolean) #

This parameter is normally on. When set to <literal>off</literal>, it disables validation of the routine body string during <xref linkend="sql-createfunction"/> and <xref linkend="sql-createprocedure"/>. Disabling validation avoids side effects of the validation process, in particular preventing false positives due to problems such as forward references. Set this parameter to <literal>off</literal> before loading functions on behalf of other users; <application>pg_dump</application> does so automatically. このパラメータは通常オンです。 offに設定すると、CREATE FUNCTIONCREATE PROCEDUREの実行中の関数本体文字列の妥当性検証を無効にします。 妥当性検証を無効にするとその妥当性検証処理の副作用を避け、前方参照による問題から起こる偽陽性(false positive)を避けることができます。 関数をロードする前にこのパラメータを他のユーザとしてoffにします。 pg_dumpはこれを自動的に行います。

default_transaction_isolation (enum) #

Each SQL transaction has an isolation level, which can be either <quote>read uncommitted</quote>, <quote>read committed</quote>, <quote>repeatable read</quote>, or <quote>serializable</quote>. This parameter controls the default isolation level of each new transaction. The default is <quote>read committed</quote>. SQLトランザクションはそれぞれ、read uncommittedread committedrepeatable read、またはserializableのいずれかの分離レベルを持ちます。 このパラメータは各新規トランザクションのデフォルトの分離レベルを制御します。 デフォルトはread committedです。

Consult <xref linkend="mvcc"/> and <xref linkend="sql-set-transaction"/> for more information. より詳細は 第13章 および SET TRANSACTION を調べてください。

split-config2-end split-config3-start
default_transaction_read_only (boolean) #

A read-only SQL transaction cannot alter non-temporary tables. This parameter controls the default read-only status of each new transaction. The default is <literal>off</literal> (read/write). 読み取り専用のSQLトランザクションでは、非一時的テーブルを変更することができません。 このパラメータは、各新規トランザクションのデフォルトの読み取りのみ状況を制御します。 デフォルトoff(読み書き)です。

Consult <xref linkend="sql-set-transaction"/> for more information. より詳細な情報はSET TRANSACTIONを調べてください。

default_transaction_deferrable (boolean) #

When running at the <literal>serializable</literal> isolation level, a deferrable read-only SQL transaction may be delayed before it is allowed to proceed. However, once it begins executing it does not incur any of the overhead required to ensure serializability; so serialization code will have no reason to force it to abort because of concurrent updates, making this option suitable for long-running read-only transactions. シリアライザブル分離レベルで運用されている場合、繰り延べ読み取り専用SQLトランザクションは、その処理の許可の前に遅延されることがあります。 しかし、ひとたび処理が開始されるとシリアライザブル可能性を保障するために必要ないかなるオーバーヘッドも発生させません。 従って、シリアル化(直列化)のコードは、このオプションを長期間にわたる読み取り専用トランザクションに対して適切な処置と位置づけ、同時実行の更新の観点から中断を強制する理由はありません。

This parameter controls the default deferrable status of each new transaction. It currently has no effect on read-write transactions or those operating at isolation levels lower than <literal>serializable</literal>. The default is <literal>off</literal>. このパラメータはそれぞれの新規トランザクションのデフォルトでの繰り延べ状態を制御します。 現時点では、読み取り専用トランザクション、またはシリアライザブルより低位の分離レベルの運用に対して効果はありません。 デフォルトはoffです。

Consult <xref linkend="sql-set-transaction"/> for more information. より詳細はSET TRANSACTIONを参照してください。

transaction_isolation (enum) #

This parameter reflects the current transaction's isolation level. At the beginning of each transaction, it is set to the current value of <xref linkend="guc-default-transaction-isolation"/>. Any subsequent attempt to change it is equivalent to a <xref linkend="sql-set-transaction"/> command. このパラメータは現在のトランザクションの隔離レベルを反映します。 個々のトランザクションの開始時、これにdefault_transaction_isolationの現在の値が設定されます。 その後のこの変数の値を変更する試みは、SET TRANSACTIONと同等です。

transaction_read_only (boolean) #

This parameter reflects the current transaction's read-only status. At the beginning of each transaction, it is set to the current value of <xref linkend="guc-default-transaction-read-only"/>. Any subsequent attempt to change it is equivalent to a <xref linkend="sql-set-transaction"/> command. このパラメータは現在のトランザクションの読み込み専用状態を反映します。 個々のトランザクションの開始時、これにdefault_transaction_read_onlyの現在の値が設定されます。 その後のこの変数の値を変更する試みは、SET TRANSACTIONと同等です。

transaction_deferrable (boolean) #

This parameter reflects the current transaction's deferrability status. At the beginning of each transaction, it is set to the current value of <xref linkend="guc-default-transaction-deferrable"/>. Any subsequent attempt to change it is equivalent to a <xref linkend="sql-set-transaction"/> command. このパラメータは現在のトランザクションの延期状態(deferrable status)を反映します。 個々のトランザクションの開始時、これにdefault_transaction_deferrableの現在の値が設定されます。 その後のこの変数の値を変更する試みは、SET TRANSACTIONと同等です。

session_replication_role (enum) #

Controls firing of replication-related triggers and rules for the current session. Possible values are <literal>origin</literal> (the default), <literal>replica</literal> and <literal>local</literal>. Setting this parameter results in discarding any previously cached query plans. Only superusers and users with the appropriate <literal>SET</literal> privilege can change this setting. 現在のセッションに対するレプリケーション関連のトリガーおよびルールの起動を制御します。 使用可能な値は、origin(デフォルト)、replicaおよびlocalです。 このパラメータを設定すると、以前にキャッシュされた問合せ計画が破棄されます。 スーパーユーザーおよび適切なSET権限を持つユーザーのみがこの設定を変更できます。

The intended use of this setting is that logical replication systems set it to <literal>replica</literal> when they are applying replicated changes. The effect of that will be that triggers and rules (that have not been altered from their default configuration) will not fire on the replica. See the <link linkend="sql-altertable"><command>ALTER TABLE</command></link> clauses <literal>ENABLE TRIGGER</literal> and <literal>ENABLE RULE</literal> for more information. この設定の使い方の趣旨としては、レプリケーションされた更新を適用する際にロジカルレプリケーションシステムがreplicaに設定するということです。 このことによる効果としては、(デフォルトの設定から変更されていない)トリガとルールはレプリカ上では起動されない、ということです。 更なる情報は、ALTER TABLE節のENABLE TRIGGERENABLE RULEをご覧ください。

PostgreSQL treats the settings <literal>origin</literal> and <literal>local</literal> the same internally. Third-party replication systems may use these two values for their internal purposes, for example using <literal>local</literal> to designate a session whose changes should not be replicated. PostgreSQLはoriginlocalの設定を内部的に同じものとして扱います。 サードパーティのレプリケーションシステムは内部的な目的、たとえばlocalを使ってレプリケーションされるべきでないセッションを指定するためにこれら2つの値を使って構いません。

Since foreign keys are implemented as triggers, setting this parameter to <literal>replica</literal> also disables all foreign key checks, which can leave data in an inconsistent state if improperly used. 外部キーはトリガとして実装されているため、このパラメータをreplicaとすることによって同時にすべての外部キー検査が無効になります。 このことにより、正しく使用しないと、データを不整合状態にしてしまう可能性があります。

statement_timeout (integer) #

Abort any statement that takes more than the specified amount of time. If <varname>log_min_error_statement</varname> is set to <literal>ERROR</literal> or lower, the statement that timed out will also be logged. If this value is specified without units, it is taken as milliseconds. A value of zero (the default) disables the timeout. コマンドがクライアントからサーバに届いた時から数えて、実行時間が指定された時間を越えた文を停止します。 log_min_error_statementERRORもしくはそれ以下に設定されている場合は、タイムアウトした文はログに書き込まれます。 この値が単位なしで指定された場合は、ミリ秒単位であるとみなします。 値がゼロ(デフォルト)の場合、これを無効にします。

The timeout is measured from the time a command arrives at the server until it is completed by the server. If multiple SQL statements appear in a single simple-Query message, the timeout is applied to each statement separately. (<productname>PostgreSQL</productname> versions before 13 usually treated the timeout as applying to the whole query string.) In extended query protocol, the timeout starts running when any query-related message (Parse, Bind, Execute, Describe) arrives, and it is canceled by completion of an Execute or Sync message. タイムアウトは、コマンドがサーバに到着したときから、サーバがそのコマンドの実行を完了するまでを基準にします。 複数のSQL文が一つの単純問い合わせメッセージに含まれる場合、タイムアウトは個々のSQL文に別々に適用されます。 (13よりも前のPostgreSQLバージョンでは、通常SQL文字列全体に対してタイムアウトが適用されていました。) 拡張問い合わせでは、タイムアウトは問い合わせに関するメッセージ(Parse、Bind、Execute、Describe)が到着したときに開始し、ExecuteあるいはSyncメッセージが完了した時にキャンセルされます。

Setting <varname>statement_timeout</varname> in <filename>postgresql.conf</filename> is not recommended because it would affect all sessions. すべてのセッションに影響することがあるので、postgresql.conf内でstatement_timeoutを設定することは推奨されません。

lock_timeout (integer) #

Abort any statement that waits longer than the specified amount of time while attempting to acquire a lock on a table, index, row, or other database object. The time limit applies separately to each lock acquisition attempt. The limit applies both to explicit locking requests (such as <command>LOCK TABLE</command>, or <command>SELECT FOR UPDATE</command> without <literal>NOWAIT</literal>) and to implicitly-acquired locks. If this value is specified without units, it is taken as milliseconds. A value of zero (the default) disables the timeout. テーブル、インデックス、行、またはその他のデータベースオブジェクトに対してロック獲得を試みている最中、指定された時間を超えて待機するいかなる命令も停止されます。 時間制限はそれぞれのロック取得の試みに対し個別に適用されます。 制限は明示的ロック要求(例えばLOCK TABLE、またはSELECT FOR UPDATE without NOWAITなど)および暗黙的に取得されるロックに適用されます。 この値が単位なしで指定された場合は、ミリ秒単位であるとみなします。 値ゼロ(デフォルト)はこの機能を無効にします。

Unlike <varname>statement_timeout</varname>, this timeout can only occur while waiting for locks. Note that if <varname>statement_timeout</varname> is nonzero, it is rather pointless to set <varname>lock_timeout</varname> to the same or larger value, since the statement timeout would always trigger first. If <varname>log_min_error_statement</varname> is set to <literal>ERROR</literal> or lower, the statement that timed out will be logged. statement_timeoutと異なり、このタイムアウトはロックを待機しているときのみ発生します。 命令によるタイムアウトは常に第一に起動されるため、もしstatement_timeoutが非ゼロであればlock_timeoutを同一、もしくはより大きい値に設定するのは的を射ていません。 log_min_error_statementERRORまたはそれより低く設定されると、時間制限を超えた命令はログに記録されます。

Setting <varname>lock_timeout</varname> in <filename>postgresql.conf</filename> is not recommended because it would affect all sessions. lock_timeoutpostgresql.confにて設定することは、すべてのセッションに影響を与える可能性があるため推奨されません。

idle_in_transaction_session_timeout (integer) #

Terminate any session that has been idle (that is, waiting for a client query) within an open transaction for longer than the specified amount of time. If this value is specified without units, it is taken as milliseconds. A value of zero (the default) disables the timeout. 開いているトランザクションが、指定された時間を超えてアイドルだった場合(つまりクライアントからの問い合わせを待っている場合)に、セッションを終了します。 この値が単位なしで指定された場合は、ミリ秒単位であるとみなします。 値がゼロ(デフォルト)の場合はタイムアウトは無効になります。

This option can be used to ensure that idle sessions do not hold locks for an unreasonable amount of time. Even when no significant locks are held, an open transaction prevents vacuuming away recently-dead tuples that may be visible only to this transaction; so remaining idle for a long time can contribute to table bloat. See <xref linkend="routine-vacuuming"/> for more details. このオプションにより、アイドル状態のセッションが不合理なほど長い時間ロックを保持することを防ぐことができます。 強いロックが保持されていなくても、開いたトランザクションは、自分にしか可視でない、最近無効になったタプルをvacuumが掃除するのを妨げます。 ですから、長時間アイドルのままになっていると、テーブルの溢れにつながります。 更なる詳細は25.1を見てください。

idle_session_timeout (integer) #

Terminate any session that has been idle (that is, waiting for a client query), but not within an open transaction, for longer than the specified amount of time. If this value is specified without units, it is taken as milliseconds. A value of zero (the default) disables the timeout. トランザクションが開いた状態ではなく、指定した時間よりも長い時間アイドル(すなわちクライアントからの問い合わせを待っている)であるセッションを終了させます。 この値が単位なしで指定された場合は、ミリ秒単位であるとみなします。 値ゼロ(デフォルトです)はタイムアウトを無効にします。

Unlike the case with an open transaction, an idle session without a transaction imposes no large costs on the server, so there is less need to enable this timeout than <varname>idle_in_transaction_session_timeout</varname>. 開いたトランザクションの場合と違って、トランザクションを伴わないアイドルなセッションは、サーバに対して大きなコストにはなりません。 ですからこのタイムアウトを有効にする必要性は、idle_in_transaction_session_timeoutよりも低いと言えます。

Be wary of enforcing this timeout on connections made through connection-pooling software or other middleware, as such a layer may not react well to unexpected connection closure. It may be helpful to enable this timeout only for interactive sessions, perhaps by applying it only to particular users. コネクションプーリングソフトウェアその他のミドルウェアを通じたコネクションに対してこのタイムアウトを強制することには慎重になってください。 そのようなレイヤは、突然のコネクション切断に対して好ましくない振る舞いをするかもしれないからです。 おそらく特定のユーザに対してのみ適用し、対話形式のセッションに対してのみこのタイムアウトを有効にするのが助けになるかもしれません。

vacuum_freeze_table_age (integer) #

<command>VACUUM</command> performs an aggressive scan if the table's <structname>pg_class</structname>.<structfield>relfrozenxid</structfield> field has reached the age specified by this setting. An aggressive scan differs from a regular <command>VACUUM</command> in that it visits every page that might contain unfrozen XIDs or MXIDs, not just those that might contain dead tuples. The default is 150 million transactions. Although users can set this value anywhere from zero to two billion, <command>VACUUM</command> will silently limit the effective value to 95% of <xref linkend="guc-autovacuum-freeze-max-age"/>, so that a periodic manual <command>VACUUM</command> has a chance to run before an anti-wraparound autovacuum is launched for the table. For more information see <xref linkend="vacuum-for-wraparound"/>. テーブルのpg_class.relfrozenxidフィールドがこの設定で指定した時期に達すると、VACUUMは積極的なテーブル走査を行います。 積極的な走査は、無効タプルを含む可能性のあるページだけではなく、凍結されていないXIDあるいはMXIDを含むすべてのページを読む点で通常のVACUUMとは異なります。 デフォルトは1.5億トランザクションです。 ユーザはこの値をゼロから20億までの任意の値に設定することができますが、VACUUMは警告することなく、周回問題対策のautovacuumがテーブルに対して起動する前に定期的な手動VACUUMが実行する機会を持つように、autovacuum_freeze_max_ageの95%に実効値を制限します。 詳細は25.1.5を参照してください。

vacuum_freeze_min_age (integer) #

Specifies the cutoff age (in transactions) that <command>VACUUM</command> should use to decide whether to trigger freezing of pages that have an older XID. The default is 50 million transactions. Although users can set this value anywhere from zero to one billion, <command>VACUUM</command> will silently limit the effective value to half the value of <xref linkend="guc-autovacuum-freeze-max-age"/>, so that there is not an unreasonably short time between forced autovacuums. For more information see <xref linkend="vacuum-for-wraparound"/>. VACUUMが、古いXIDを持つページをフリーズするきっかけとするかどうかを決定する、カットオフ年代を(トランザクション単位で)指定します。 デフォルトは5千万トランザクションです。 ユーザはこの値を0から10億までの間で任意の値に設定することができますが、VACUUMは警告なくautovacuum_freeze_max_ageの半分までの値に値を制限します。 このため、強制的なautovacuumの間隔が不合理に短くなることはありません。 詳細は25.1.5を参照してください。

vacuum_failsafe_age (integer) #

Specifies the maximum age (in transactions) that a table's <structname>pg_class</structname>.<structfield>relfrozenxid</structfield> field can attain before <command>VACUUM</command> takes extraordinary measures to avoid system-wide transaction ID wraparound failure. This is <command>VACUUM</command>'s strategy of last resort. The failsafe typically triggers when an autovacuum to prevent transaction ID wraparound has already been running for some time, though it's possible for the failsafe to trigger during any <command>VACUUM</command>. VACUUMがシステム全体に渡るトランザクションID周回障害を避けるために異例の措置を取るようになる、テーブルのpg_class.relfrozenxidフィールドが到達する最大の(トランザクション数単位での)年齢を指定します。 これはVACUUMの最後の手段となる戦略です。 この安全機構は典型的には、トランザクションID周回を防ぐための自動バキュームがすでに走っているときに起動されます。 しかし、すべてのVACUUMの実行中にこの安全機構が起動する可能性があります。

When the failsafe is triggered, any cost-based delay that is in effect will no longer be applied, further non-essential maintenance tasks (such as index vacuuming) are bypassed, and any <glossterm linkend="glossary-buffer-access-strategy">Buffer Access Strategy</glossterm> in use will be disabled resulting in <command>VACUUM</command> being free to make use of all of <glossterm linkend="glossary-shared-memory">shared buffers</glossterm>. この安全機構が起動すると、すべての有効なコストに基づく遅延はもはや適用されず、(インデックスのバキュームのような)必須ではない保守タスクは迂回されます。 使用中のバッファアクセスストラテジは無効になり、その結果VACUUM共有バッファのすべてを自由に使用することになります。

The default is 1.6 billion transactions. Although users can set this value anywhere from zero to 2.1 billion, <command>VACUUM</command> will silently adjust the effective value to no less than 105% of <xref linkend="guc-autovacuum-freeze-max-age"/>. デフォルトは16億トランザクションです。 ユーザはこの値をゼロから21億までの間で設定できますが、VACUUMautovacuum_freeze_max_ageの105%よりも小さくならないように実際の値を調整します。

vacuum_multixact_freeze_table_age (integer) #

<command>VACUUM</command> performs an aggressive scan if the table's <structname>pg_class</structname>.<structfield>relminmxid</structfield> field has reached the age specified by this setting. An aggressive scan differs from a regular <command>VACUUM</command> in that it visits every page that might contain unfrozen XIDs or MXIDs, not just those that might contain dead tuples. The default is 150 million multixacts. Although users can set this value anywhere from zero to two billion, <command>VACUUM</command> will silently limit the effective value to 95% of <xref linkend="guc-autovacuum-multixact-freeze-max-age"/>, so that a periodic manual <command>VACUUM</command> has a chance to run before an anti-wraparound is launched for the table. For more information see <xref linkend="vacuum-for-multixact-wraparound"/>. pg_class.relminmxidフィールドがこの設定値で指定した年代に達するとVACUUMはテーブルの積極的なスキャンを行います。 積極的なスキャンは、無効タプルを含む可能性のあるページだけではなく、凍結XIDあるいはMXIDを含むすべてのページを読む点で通常のVACUUMとは異なります。 デフォルトは1億5千万トランザクションです。 ユーザは0から20億まで任意の値を設定できますが、テーブルに対してラップアラウンド防止処理が起動される前に定期的な手動VACUUMが走ることができるように、VACUUMautovacuum_multixact_freeze_max_ageの95%に暗黙的に制限します。 詳細は25.1.5.1をご覧ください。

vacuum_multixact_freeze_min_age (integer) #

Specifies the cutoff age (in multixacts) that <command>VACUUM</command> should use to decide whether to trigger freezing of pages with an older multixact ID. The default is 5 million multixacts. Although users can set this value anywhere from zero to one billion, <command>VACUUM</command> will silently limit the effective value to half the value of <xref linkend="guc-autovacuum-multixact-freeze-max-age"/>, so that there is not an unreasonably short time between forced autovacuums. For more information see <xref linkend="vacuum-for-multixact-wraparound"/>. VACUUMがテーブルをスキャンする際に、ページを凍結するきっかけとするかどうかを決める下限値をマルチトランザクション単位で指定します。 デフォルトは500万マルチトランザクションです。 ユーザは0から10億まで任意の値を設定できますが、強制的な自動バキュームの間隔が短くなり過ぎないように、VACUUMautovacuum_multixact_freeze_max_ageの半分に暗黙的に実効的な値を制限します。 詳細は25.1.5.1をご覧ください。

vacuum_multixact_failsafe_age (integer) #

Specifies the maximum age (in multixacts) that a table's <structname>pg_class</structname>.<structfield>relminmxid</structfield> field can attain before <command>VACUUM</command> takes extraordinary measures to avoid system-wide multixact ID wraparound failure. This is <command>VACUUM</command>'s strategy of last resort. The failsafe typically triggers when an autovacuum to prevent transaction ID wraparound has already been running for some time, though it's possible for the failsafe to trigger during any <command>VACUUM</command>. VACUUMがシステム全体マルチトランザクションID周回障害を避けるために異例の措置を取るようになる、テーブルのpg_class.relminmxidフィールドが到達する最大の(マルチトランザクション数単位での)年齢を指定します。 これはVACUUM最後の手段となる戦略です。 この安全機構は典型的には、トランザクションID周回を防ぐための自動バキュームがすでに走っているときに起動されます。 しかし、すべてのVACUUMの実行中にこの安全機構が起動する可能性があります。

When the failsafe is triggered, any cost-based delay that is in effect will no longer be applied, and further non-essential maintenance tasks (such as index vacuuming) are bypassed. この安全機構が起動すると、すべての有効なコストに基づく遅延はもはや適用されず、(インデックスのバキュームのような)必須ではない保守タスクは迂回されます。

The default is 1.6 billion multixacts. Although users can set this value anywhere from zero to 2.1 billion, <command>VACUUM</command> will silently adjust the effective value to no less than 105% of <xref linkend="guc-autovacuum-multixact-freeze-max-age"/>. デフォルトは16億マルチトランザクションです。 ユーザはこの値をゼロから21億までの間で設定できますが、VACUUMautovacuum_multixact_freeze_max_ageの105%よりも小さくならないように実際の値を調整します。

bytea_output (enum) #

Sets the output format for values of type <type>bytea</type>. Valid values are <literal>hex</literal> (the default) and <literal>escape</literal> (the traditional PostgreSQL format). See <xref linkend="datatype-binary"/> for more information. The <type>bytea</type> type always accepts both formats on input, regardless of this setting. bytea型の値の出力形式を設定します。 有効な値はhex(デフォルト)、およびescape(PostgreSQLの伝統的な書式)です。 より詳細は8.4を参照してください。 bytea型は常にこの設定に係わらず、入力時に双方の書式を受け付けます。

xmlbinary (enum) #

Sets how binary values are to be encoded in XML. This applies for example when <type>bytea</type> values are converted to XML by the functions <function>xmlelement</function> or <function>xmlforest</function>. Possible values are <literal>base64</literal> and <literal>hex</literal>, which are both defined in the XML Schema standard. The default is <literal>base64</literal>. For further information about XML-related functions, see <xref linkend="functions-xml"/>. バイナリデータをXMLに符号化する方法を設定します。 例えばこれは、xmlelementxmlforest関数でbytea値をXMLに変換する際に適用されます。 取り得る値はbase64hexです。 どちらもXMLスキーマ標準で定義されています。 デフォルトはbase64です。 XMLに関連した関数については9.15を参照してください。

The actual choice here is mostly a matter of taste, constrained only by possible restrictions in client applications. Both methods support all possible values, although the hex encoding will be somewhat larger than the base64 encoding. 実のところこの選択はほとんど趣味の問題で、クライアントアプリケーションで起こり得る制限のみに制約されます。 どちらの方法もすべての値をサポートしますが、hex符号化方式はbase64符号化方式より少し大きくなります。

xmloption (enum) #

Sets whether <literal>DOCUMENT</literal> or <literal>CONTENT</literal> is implicit when converting between XML and character string values. See <xref linkend="datatype-xml"/> for a description of this. Valid values are <literal>DOCUMENT</literal> and <literal>CONTENT</literal>. The default is <literal>CONTENT</literal>. XMLと文字列値との変換時にDOCUMENTとするかCONTENTとするかを設定します。 この説明については8.13を参照してください。 有効な値はDOCUMENTCONTENTです。 デフォルトはCONTENTです。

According to the SQL standard, the command to set this option is 標準SQLに従うと、このオプションを設定するコマンドは以下のようになります。

SET XML OPTION { DOCUMENT | CONTENT };

This syntax is also available in PostgreSQL. この構文はPostgreSQLでも使用可能です。

gin_pending_list_limit (integer) #

Sets the maximum size of a GIN index's pending list, which is used when <literal>fastupdate</literal> is enabled. If the list grows larger than this maximum size, it is cleaned up by moving the entries in it to the index's main GIN data structure in bulk. If this value is specified without units, it is taken as kilobytes. The default is four megabytes (<literal>4MB</literal>). This setting can be overridden for individual GIN indexes by changing index storage parameters. See <xref linkend="gin-fast-update"/> and <xref linkend="gin-tips"/> for more information. fastupdateが有効なときに使用されるGINインデックスのペンディングリストの最大サイズを設定します。 リストがこの設定値よりも大きくなったら、エントリをインデックスのGINの主データ構造に一括転送してリストはクリアされます。 この値が単位なしで指定された場合は、キロバイト単位であるとみなします。 デフォルトは4メガバイト(4MB)です。 この設定は、個々のGINインデックスに対してインデックスストレージパラメータを変更することにより、上書きできます。 更なる情報については、70.4.170.5を参照してください。

createrole_self_grant (string) #

If a user who has <literal>CREATEROLE</literal> but not <literal>SUPERUSER</literal> creates a role, and if this is set to a non-empty value, the newly-created role will be granted to the creating user with the options specified. The value must be <literal>set</literal>, <literal>inherit</literal>, or a comma-separated list of these. The default value is an empty string, which disables the feature. CREATEROLEを持ち、SUPERUSERを持たないユーザがロールを作成し、これが空でない値に設定されている場合、新しく作成されたロールは、この指定されたオプションを持ち、ロールを作成したユーザに付与されます。 値は、setinherit、またはこれらのリストをカンマで区切ったものである必要があります。 デフォルト値は空の文字列であるため、この機能は無効になります。

The purpose of this option is to allow a <literal>CREATEROLE</literal> user who is not a superuser to automatically inherit, or automatically gain the ability to <literal>SET ROLE</literal> to, any created users. Since a <literal>CREATEROLE</literal> user is always implicitly granted <literal>ADMIN OPTION</literal> on created roles, that user could always execute a <literal>GRANT</literal> statement that would achieve the same effect as this setting. However, it can be convenient for usability reasons if the grant happens automatically. A superuser automatically inherits the privileges of every role and can always <literal>SET ROLE</literal> to any role, and this setting can be used to produce a similar behavior for <literal>CREATEROLE</literal> users for users which they create. このオプションの目的は、CREATEROLEが許可されているスーパーユーザではないユーザが、作成されたユーザを自動的に継承するか、またはSET ROLE権限を自動的に取得できるようにすることです。 CREATEROLEユーザは、作成されたロールに対して常に暗黙的にADMIN OPTIONが付与されるため、そのユーザは、この設定と同じ効果を達成するGRANT文を常に実行できます。 しかし、権限付与が自動的に行われることは、使用上の理由から便利です。 スーパーユーザは、すべてのロールの権限を自動的に継承し、どのロールに対しても常にSET ROLEできます。 また、この設定を使用して、CREATEROLEユーザが作成したユーザに対して同様の動作を生成できます。

20.11.2. ロケールと書式設定 #

<title>Locale and Formatting</title>
DateStyle (string) #

Sets the display format for date and time values, as well as the rules for interpreting ambiguous date input values. For historical reasons, this variable contains two independent components: the output format specification (<literal>ISO</literal>, <literal>Postgres</literal>, <literal>SQL</literal>, or <literal>German</literal>) and the input/output specification for year/month/day ordering (<literal>DMY</literal>, <literal>MDY</literal>, or <literal>YMD</literal>). These can be set separately or together. The keywords <literal>Euro</literal> and <literal>European</literal> are synonyms for <literal>DMY</literal>; the keywords <literal>US</literal>, <literal>NonEuro</literal>, and <literal>NonEuropean</literal> are synonyms for <literal>MDY</literal>. See <xref linkend="datatype-datetime"/> for more information. The built-in default is <literal>ISO, MDY</literal>, but <application>initdb</application> will initialize the configuration file with a setting that corresponds to the behavior of the chosen <varname>lc_time</varname> locale. 日付時刻値の表示書式を設定し、曖昧な日付入力の解釈規則を設定します。 歴史的な理由により、この変数には2つの独立した要素が含まれています。 出力書式指定(ISOPostgresSQLGerman)と年/月/日の順序の入出力指定(DMYMDYYMD)です。 これらは分けて設定することもまとめて設定することもできます。 EuroおよびEuropeanキーワードはDMYの同義語であり、USNonEuroNonEuropeanMDYの同義語です。 詳細は8.5を参照してください。 組み込みのデフォルトはISO, MDYですが、initdbにより、選択されたlc_timeロケールの動作に対応した設定で設定ファイルが初期化されます。

IntervalStyle (enum) #

Sets the display format for interval values. The value <literal>sql_standard</literal> will produce output matching <acronym>SQL</acronym> standard interval literals. The value <literal>postgres</literal> (which is the default) will produce output matching <productname>PostgreSQL</productname> releases prior to 8.4 when the <xref linkend="guc-datestyle"/> parameter was set to <literal>ISO</literal>. The value <literal>postgres_verbose</literal> will produce output matching <productname>PostgreSQL</productname> releases prior to 8.4 when the <varname>DateStyle</varname> parameter was set to non-<literal>ISO</literal> output. The value <literal>iso_8601</literal> will produce output matching the time interval <quote>format with designators</quote> defined in section 4.4.3.2 of ISO 8601. 間隔の値の表示形式を設定します。sql_standard値は、SQL標準間隔リテラルに一致する出力を生成します。 (デフォルトの)値postgresは、DateStyleパラメータがISOに設定されている場合、リリース8.4以前のPostgreSQLに一致する出力を生成します。 値postgres_verboseは、DateStyleパラメータが非ISO出力に設定されている場合、リリース8.4以前のPostgreSQLに一致する出力を生成します。 値iso_8601は、ISO 8601の4.4.3.2節で定義されている時間間隔format with designatorsに一致する出力を生成します。

The <varname>IntervalStyle</varname> parameter also affects the interpretation of ambiguous interval input. See <xref linkend="datatype-interval-input"/> for more information. またIntervalStyleパラメータはあいまいに入力された時間間隔の解釈に影響を与えます。 詳細については8.5.4を参照してください。

TimeZone (string) #

Sets the time zone for displaying and interpreting time stamps. The built-in default is <literal>GMT</literal>, but that is typically overridden in <filename>postgresql.conf</filename>; <application>initdb</application> will install a setting there corresponding to its system environment. See <xref linkend="datatype-timezones"/> for more information. 表示用およびタイムスタンプ解釈用の時間帯を設定します。 組み込まれているデフォルトはGMTですが、通常はpostgresql.confにより上書きされます。initdbによりこれらと関連した設定をシステム環境にインストールされます。 詳細は8.5.3を参照してください。

timezone_abbreviations (string) #

Sets the collection of time zone abbreviations that will be accepted by the server for datetime input. The default is <literal>'Default'</literal>, which is a collection that works in most of the world; there are also <literal>'Australia'</literal> and <literal>'India'</literal>, and other collections can be defined for a particular installation. See <xref linkend="datetime-config-files"/> for more information. サーバで日付時刻の入力として受付け可能となる時間帯省略形の集合を設定します。 デフォルトは'Default'です。 これはほぼ全世界で通じる集合です。 また、AustraliaIndia、その他特定のインストレーションで定義可能な集合が存在します。 詳細はB.4を参照してください。

extra_float_digits (integer) #

This parameter adjusts the number of digits used for textual output of floating-point values, including <type>float4</type>, <type>float8</type>, and geometric data types. このパラメータは、float4float8、幾何データ型などにおいて、浮動小数点数値のテキスト形式の出力で使用される桁数を調整します。

If the value is 1 (the default) or above, float values are output in shortest-precise format; see <xref linkend="datatype-float"/>. The actual number of digits generated depends only on the value being output, not on the value of this parameter. At most 17 digits are required for <type>float8</type> values, and 9 for <type>float4</type> values. This format is both fast and precise, preserving the original binary float value exactly when correctly read. For historical compatibility, values up to 3 are permitted. この値が1(デフォルト)あるいはそれ以上なら、浮動小数点数値の出力は最も短い精度の形式で出力されます。 8.1.3を参照してください。 生成される実際の桁数は出力される値にのみ依存します。 float8値では最大でも17桁、float4値では最大9桁必要です。 この形式は高速かつ高精度で、正しく読まれる際には元の2進数における浮動小数点値を正確に保存します。 歴史的な互換性の理由により、3までの値が許容されています。

If the value is zero or negative, then the output is rounded to a given decimal precision. The precision used is the standard number of digits for the type (<literal>FLT_DIG</literal> or <literal>DBL_DIG</literal> as appropriate) reduced according to the value of this parameter. (For example, specifying -1 will cause <type>float4</type> values to be output rounded to 5 significant digits, and <type>float8</type> values rounded to 14 digits.) This format is slower and does not preserve all the bits of the binary float value, but may be more human-readable. この値がゼロまたは負なら、出力は与えられた10進精度に丸められます。 使用される精度は、各々の型の標準的の桁数(型に応じてFLT_DIGあるいはDBL_DIG)がこのパラメータの値により制限されたものになります。 (たとえば、-1にするとfloat4値は5桁に、float8値では14桁に丸められます。) この形式は低速、かつ元の2進数における浮動小数点値のビットを保存しませんが、人間にとってより読みやすいかも知れません。

注記

The meaning of this parameter, and its default value, changed in <productname>PostgreSQL</productname> 12; see <xref linkend="datatype-float"/> for further discussion. このパラメータの意味とデフォルト値はPostgreSQL 12で変更されました。 更なる議論については8.1.3をご覧ください。

client_encoding (string) #

Sets the client-side encoding (character set). The default is to use the database encoding. The character sets supported by the <productname>PostgreSQL</productname> server are described in <xref linkend="multibyte-charset-supported"/>. クライアント側符号化方式(文字セット)を設定します。デフォルトはデータベース符号化方式を使用します。 PostgreSQLサーバでサポートされている文字セットは24.3.1に記載されています。

lc_messages (string) #

Sets the language in which messages are displayed. Acceptable values are system-dependent; see <xref linkend="locale"/> for more information. If this variable is set to the empty string (which is the default) then the value is inherited from the execution environment of the server in a system-dependent way. メッセージが表示される言語を設定します。使用可能な値はシステムに依存します。詳細については24.1を参照してください。 この変数が空に設定された場合(これがデフォルトです)、値はシステムに依存する方法でサーバの実行環境から継承されます。

On some systems, this locale category does not exist. Setting this variable will still work, but there will be no effect. Also, there is a chance that no translated messages for the desired language exist. In that case you will continue to see the English messages. システムによっては、このロケールのカテゴリが存在しません。この変数を設定することはできますが、実効性はありません。 また、指定の言語に翻訳されたメッセージが存在しないこともあります。 その場合は、引き続き英語のメッセージが表示されます。

Only superusers and users with the appropriate <literal>SET</literal> privilege can change this setting. この設定を変更できるのは、スーパーユーザと適切なSET権限を持つユーザだけです。

lc_monetary (string) #

Sets the locale to use for formatting monetary amounts, for example with the <function>to_char</function> family of functions. Acceptable values are system-dependent; see <xref linkend="locale"/> for more information. If this variable is set to the empty string (which is the default) then the value is inherited from the execution environment of the server in a system-dependent way. 通貨書式で使用するロケールを設定します。 例えば、to_char()系の関数で使用します。 使用可能な値はシステムに依存します。 詳細については24.1を参照してください。 この変数が空に設定された場合(これがデフォルトです)、値はシステムに依存する方法でサーバの実行環境から継承されます。

lc_numeric (string) #

Sets the locale to use for formatting numbers, for example with the <function>to_char</function> family of functions. Acceptable values are system-dependent; see <xref linkend="locale"/> for more information. If this variable is set to the empty string (which is the default) then the value is inherited from the execution environment of the server in a system-dependent way. 数字の書式で使用するロケールを設定します。 例えば、to_char系の関数で使用します。 使用可能な値はシステムに依存します。 詳細については24.1を参照してください。 この変数が空に設定された場合(これがデフォルトです)、値はシステムに依存する方法でサーバの実行環境から継承されます。

lc_time (string) #

Sets the locale to use for formatting dates and times, for example with the <function>to_char</function> family of functions. Acceptable values are system-dependent; see <xref linkend="locale"/> for more information. If this variable is set to the empty string (which is the default) then the value is inherited from the execution environment of the server in a system-dependent way. 例えばto_char系関数における、日付と時間の書式で使用するロケールを設定します。 使用可能な値はシステムに依存します。 詳細については24.1を参照してください。 この変数が空に設定された場合(これがデフォルトです)、値はシステムに依存する方法でサーバの実行環境から継承されます。

icu_validation_level (enum) #

When ICU locale validation problems are encountered, controls which <link linkend="runtime-config-severity-levels">message level</link> is used to report the problem. Valid values are <literal>DISABLED</literal>, <literal>DEBUG5</literal>, <literal>DEBUG4</literal>, <literal>DEBUG3</literal>, <literal>DEBUG2</literal>, <literal>DEBUG1</literal>, <literal>INFO</literal>, <literal>NOTICE</literal>, <literal>WARNING</literal>, <literal>ERROR</literal>, and <literal>LOG</literal>. ICUロケール検証の問題が発生した場合、問題を報告するために使用されるメッセージレベルを制御します。 有効な値は、DISABLEDDEBUG5DEBUG4DEBUG3DEBUG2DEBUG1INFONOTICEWARNINGERROR、および LOGです。

If set to <literal>DISABLED</literal>, does not report validation problems at all. Otherwise reports problems at the given message level. The default is <literal>WARNING</literal>. DISABLEDに設定すると、検証で見つかった問題は全く報告されません。 それ以外の場合は、指定したメッセージレベルの問題が報告されます。 デフォルトはWARNINGです。

default_text_search_config (string) #

Selects the text search configuration that is used by those variants of the text search functions that do not have an explicit argument specifying the configuration. See <xref linkend="textsearch"/> for further information. The built-in default is <literal>pg_catalog.simple</literal>, but <application>initdb</application> will initialize the configuration file with a setting that corresponds to the chosen <varname>lc_ctype</varname> locale, if a configuration matching that locale can be identified. 明示的な設定指定引数を持たないテキスト検索関数の亜種で使用される、テキスト検索設定を選択します。 詳細は第12章を参照してください。 組み込みのデフォルトはpg_catalog.simpleですが、initdbは、ロケールに合う設定を認識することができれば、選択されたlc_ctypeロケールに対応した設定で設定ファイルを初期化します。

20.11.3. 共有ライブラリのプリロード #

<title>Shared Library Preloading</title>

Several settings are available for preloading shared libraries into the server, in order to load additional functionality or achieve performance benefits. For example, a setting of <literal>'$libdir/mylib'</literal> would cause <literal>mylib.so</literal> (or on some platforms, <literal>mylib.sl</literal>) to be preloaded from the installation's standard library directory. The differences between the settings are when they take effect and what privileges are required to change them. 追加機能や性能改良の目的で共有ライブラリをプリロードするいくつかの設定があります。 たとえば'$libdir/mylib'を設定するとmylib.so(あるいは他のプラットフォームではmylib.sl)を導入設定したの標準ディレクトリからプリロードします。 各設定の違いは、設定変更を行うためにいつ、どのような権限が必要かにあります。

<productname>PostgreSQL</productname> procedural language libraries can be preloaded in this way, typically by using the syntax <literal>'$libdir/plXXX'</literal> where <literal>XXX</literal> is <literal>pgsql</literal>, <literal>perl</literal>, <literal>tcl</literal>, or <literal>python</literal>. 典型的には'$libdir/plXXX'のような構文を用いてPostgreSQL手続き言語ライブラリをこの方法でプリロードできます。 XXXpgsqlperltclpythonです。

Only shared libraries specifically intended to be used with PostgreSQL can be loaded this way. Every PostgreSQL-supported library has a <quote>magic block</quote> that is checked to guarantee compatibility. For this reason, non-PostgreSQL libraries cannot be loaded in this way. You might be able to use operating-system facilities such as <envar>LD_PRELOAD</envar> for that. PostgreSQLで使用することを意図したライブラリだけがこの方法でロードできます。 すべてのPostgreSQL用のライブラリはmagic blockを持ち、互換性を保証するためにチェックされます。 ですからPostgreSQL用ではないライブラリはこの方法ではロードできません。 LD_PRELOADのようなOSの機能を使えばあるいは使用できるかもしれません。

In general, refer to the documentation of a specific module for the recommended way to load that module. 一般的に言ってモジュールのドキュメントを参照し、推奨される方法でロードしてください。

local_preload_libraries (string) #

This variable specifies one or more shared libraries that are to be preloaded at connection start. It contains a comma-separated list of library names, where each name is interpreted as for the <link linkend="sql-load"><command>LOAD</command></link> command. Whitespace between entries is ignored; surround a library name with double quotes if you need to include whitespace or commas in the name. The parameter value only takes effect at the start of the connection. Subsequent changes have no effect. If a specified library is not found, the connection attempt will fail. この変数は、接続時に事前読み込みされる、1つまたは複数の共有ライブラリを指定します。 ここにはカンマ区切りでライブラリ名のリストを格納し、各々の名前はLOADコマンドで解釈されます。 項目の間の空白は無視されます。 名前の中に空白あるいはカンマを含める場合は、二重引用符で囲ってください。 このパラメータは、接続の開始時にのみ効果があります。 以降の変更は効果がありません。 もし指定したライブラリが見つからない場合は、接続は失敗します。

This option can be set by any user. Because of that, the libraries that can be loaded are restricted to those appearing in the <filename>plugins</filename> subdirectory of the installation's standard library directory. (It is the database administrator's responsibility to ensure that only <quote>safe</quote> libraries are installed there.) Entries in <varname>local_preload_libraries</varname> can specify this directory explicitly, for example <literal>$libdir/plugins/mylib</literal>, or just specify the library name &mdash; <literal>mylib</literal> would have the same effect as <literal>$libdir/plugins/mylib</literal>. このオプションはすべてのユーザが設定できます。 この理由で、読み込み可能なライブラリはインストレーションの共有ライブラリディレクトリのサブディレクトリplugins内にあるものに制限されています。 (確実に安全なライブラリのみをここにインストールすることはデータベース管理者の責任です。) local_preload_libraries内の項目で、たとえば$libdir/plugins/mylibのようにこのディレクトリを明示的に指定することも、単にライブラリ名を指定することも可能です。 mylib$libdir/plugins/mylibと同じ効果です。

The intent of this feature is to allow unprivileged users to load debugging or performance-measurement libraries into specific sessions without requiring an explicit <command>LOAD</command> command. To that end, it would be typical to set this parameter using the <envar>PGOPTIONS</envar> environment variable on the client or by using <command>ALTER ROLE SET</command>. この機能の意図するところは、明示的なLOADコマンドを使わずに、特定のセッションにおいて非特権ユーザがデバッグ用あるいは性能計測用のライブラリをロードできるようにすることにあります。 そのためにも、クライアント側でPGOPTIONS環境変数を使う、あるいはALTER ROLE SETを使うことが典型的になるでしょう。

However, unless a module is specifically designed to be used in this way by non-superusers, this is usually not the right setting to use. Look at <xref linkend="guc-session-preload-libraries"/> instead. しかし、モジュールが特にスーパーユーザ以外に使われることを意図しているのでない限り、通常この方法は正しい使い方ではありません。 代わりにsession_preload_librariesを見てください。

session_preload_libraries (string) #

This variable specifies one or more shared libraries that are to be preloaded at connection start. It contains a comma-separated list of library names, where each name is interpreted as for the <link linkend="sql-load"><command>LOAD</command></link> command. Whitespace between entries is ignored; surround a library name with double quotes if you need to include whitespace or commas in the name. The parameter value only takes effect at the start of the connection. Subsequent changes have no effect. If a specified library is not found, the connection attempt will fail. この変数は、接続時に事前読み込みされる、1つまたは複数の共有ライブラリを指定します。 ここにはカンマ区切りでライブラリ名のリストを格納し、各々の名前はLOADコマンドで解釈されます。 項目の間の空白は無視されます。 名前の中に空白あるいはカンマを含める場合は、二重引用符で囲ってください。 このパラメータは、接続の開始時にのみ効果があります。 以降の変更は効果がありません。 もし指定したライブラリが見つからない場合は、接続は失敗します。 Only superusers and users with the appropriate <literal>SET</literal> privilege can change this setting. この設定を変更できるのは、スーパーユーザと適切なSET権限を持つユーザだけです。

The intent of this feature is to allow debugging or performance-measurement libraries to be loaded into specific sessions without an explicit <command>LOAD</command> command being given. For example, <xref linkend="auto-explain"/> could be enabled for all sessions under a given user name by setting this parameter with <command>ALTER ROLE SET</command>. Also, this parameter can be changed without restarting the server (but changes only take effect when a new session is started), so it is easier to add new modules this way, even if they should apply to all sessions. この機能は、デバッグや性能測定の目的でLOADコマンドを使わずに特定のセッションでライブラリをロードする目的で使われます。 たとえばALTER ROLE SETで設定することにより、特定のユーザが開始するすべてのセッションでauto_explainが有効になります。 また、このパラメータはサーバを再起動せずに変更できます(しかし変更は新しいセッションが開始するときにのみ有効となります)。すべてのセッションで有効にしたいのであれば、この方法で新しいモジュールを容易に追加できます。

Unlike <xref linkend="guc-shared-preload-libraries"/>, there is no large performance advantage to loading a library at session start rather than when it is first used. There is some advantage, however, when connection pooling is used. shared_preload_librariesと違って、ライブラリがはじめて使われるときにロードする方法と比べてセッションが開始するときにライブラリをロードする方法には大きな性能的な優位性はありません。 しかし、コネクションプーリングを使うのであれば、いくらか優位性があります。

shared_preload_libraries (string) #

This variable specifies one or more shared libraries to be preloaded at server start. It contains a comma-separated list of library names, where each name is interpreted as for the <link linkend="sql-load"><command>LOAD</command></link> command. Whitespace between entries is ignored; surround a library name with double quotes if you need to include whitespace or commas in the name. This parameter can only be set at server start. If a specified library is not found, the server will fail to start. この変数はサーバ起動時にプリロードされる一つ以上の共有ライブラリを指定します。 ここにはカンマ区切りでライブラリ名のリストを格納し、各々の名前はLOADコマンドで解釈されます。 スーパーユーザだけがこの設定を変更できます。 このパラメータはサーバ起動時にのみ設定可能です。 もし指定したライブラリが見つからない場合は、起動は失敗します。

Some libraries need to perform certain operations that can only take place at postmaster start, such as allocating shared memory, reserving light-weight locks, or starting background workers. Those libraries must be loaded at server start through this parameter. See the documentation of each library for details. ライブラリによってはpostmaster起動時にのみ可能な操作を実行する必要があるものがあります。 たとえば、共有メモリの獲得、軽量ロックの予約、バックグラウンドワーカーの起動などです。 このようなライブラリはこのパラメータを使ってサーバ起動時にロードしなければなりません。 詳細は各ライブラリのドキュメントを見てください。

Other libraries can also be preloaded. By preloading a shared library, the library startup time is avoided when the library is first used. However, the time to start each new server process might increase slightly, even if that process never uses the library. So this parameter is recommended only for libraries that will be used in most sessions. Also, changing this parameter requires a server restart, so this is not the right setting to use for short-term debugging tasks, say. Use <xref linkend="guc-session-preload-libraries"/> for that instead. これ以外のライブラリもプリロードできます。 共有ライブラリをプリロードすることにより、最初にライブラリが使われる際にライブラリが起動する時間を避けることができます。 しかし、そのライブラリが使われないとしても、サーバプロセスが起動する時間がわずかに長くなる可能性があります。 したがって、この方法は、ほとんどのセッションで使われるライブラリにのみ使用することを推奨します。 また、パラメータの変更にはサーバの再起動が必要になります。 ですから、たとえば短期のデバッグ仕事にこの設定を使うのは適当とは言えません。 session_preload_librariesを代わりに使ってください。

注記

On Windows hosts, preloading a library at server start will not reduce the time required to start each new server process; each server process will re-load all preload libraries. However, <varname>shared_preload_libraries </varname> is still useful on Windows hosts for libraries that need to perform operations at postmaster start time. Windowsのホストでは、ライブラリのプリロードは、新しいサーバプロセスの起動に要する時間を短縮しません。 個々のサーバプロセスは、すべてのプリロードライブラリを再読み込みします。 それでもpostmaster起動時に操作を実行しなければならないライブラリを使用するWindowsホストにとってはshared_preload_librariesは有用です。

jit_provider (string) #

This variable is the name of the JIT provider library to be used (see <xref linkend="jit-pluggable"/>). The default is <literal>llvmjit</literal>. This parameter can only be set at server start. この変数は、使用するJITプロバイダライブラリ(32.4.2参照)の名前です。 デフォルトはllvmjitです。 このパラメータはサーバ起動時にのみ設定可能です。

If set to a non-existent library, <acronym>JIT</acronym> will not be available, but no error will be raised. This allows JIT support to be installed separately from the main <productname>PostgreSQL</productname> package. 存在しないライブラリが指定されると、JITは利用できませんが、エラーは起こりません。 これにより、PostgreSQLパッケージとは別にJITサポートをインストールできるようになります。

20.11.4. その他のデフォルト #

<title>Other Defaults</title>
dynamic_library_path (string) #

If a dynamically loadable module needs to be opened and the file name specified in the <command>CREATE FUNCTION</command> or <command>LOAD</command> command does not have a directory component (i.e., the name does not contain a slash), the system will search this path for the required file. オープンする必要がある動的ロード可能なモジュールについて、そのCREATE FUNCTIONLOADコマンドで指定されたファイル名にディレクトリ要素がなく(つまり、名前にスラッシュが含まれずに)指定された場合、システムは必要なファイルをこのパスから検索します。

The value for <varname>dynamic_library_path</varname> must be a list of absolute directory paths separated by colons (or semi-colons on Windows). If a list element starts with the special string <literal>$libdir</literal>, the compiled-in <productname>PostgreSQL</productname> package library directory is substituted for <literal>$libdir</literal>; this is where the modules provided by the standard <productname>PostgreSQL</productname> distribution are installed. (Use <literal>pg_config &#45;-pkglibdir</literal> to find out the name of this directory.) For example: dynamic_library_pathの値は、絶対パスのディレクトリ名をコロン(Windowsの場合はセミコロン)で区切った一覧です。 この一覧の要素が特別な$libdirという値から始まる場合、コンパイルされたPostgreSQLパッケージのライブラリディレクトリで$libdirは置換されます。 ここには、PostgreSQLの標準配布物により提供されるモジュールがインストールされます (このディレクトリ名を表示するには、pg_config --pkglibdir を使用してください)。 例を以下に示します。

dynamic_library_path = '/usr/local/lib/postgresql:/home/my_project/lib:$libdir'

or, in a Windows environment: Windows環境の場合は以下です。

dynamic_library_path = 'C:\tools\postgresql;H:\my_project\lib;$libdir'

The default value for this parameter is <literal>'$libdir'</literal>. If the value is set to an empty string, the automatic path search is turned off. このパラメータのデフォルト値は'$libdir'です。 この値が空に設定された場合、自動的なパス検索は無効になります。

This parameter can be changed at run time by superusers and users with the appropriate <literal>SET</literal> privilege, but a setting done that way will only persist until the end of the client connection, so this method should be reserved for development purposes. The recommended way to set this parameter is in the <filename>postgresql.conf</filename> configuration file. このパラメータはスーパーユーザと、適切なSET権限を持つユーザによって実行時に変更することができますが、この方法での設定は、そのクライアント接続が終わるまでしか有効になりません。 ですので、この方法は開発目的でのみ使用すべきです。 推奨方法はこのパラメータをpostgresql.conf設定ファイル内で設定することです。

gin_fuzzy_search_limit (integer) #

Soft upper limit of the size of the set returned by GIN index scans. For more information see <xref linkend="gin-tips"/>. GINインデックス走査により返されるセットのソフトな上限サイズです。 詳細は70.5を参照してください。