Commit 445732a5 authored by Bruce Momjian's avatar Bruce Momjian

Point out that CREATE INDEX uses sorts and hence sort_mem GUC parameter.

parent aef9dbdb
<!-- <!--
$Header: /cvsroot/pgsql/doc/src/sgml/runtime.sgml,v 1.135 2002/09/02 13:45:30 tgl Exp $ $Header: /cvsroot/pgsql/doc/src/sgml/runtime.sgml,v 1.136 2002/09/17 21:41:47 momjian Exp $
--> -->
<Chapter Id="runtime"> <Chapter Id="runtime">
...@@ -1784,12 +1784,13 @@ dynamic_library_path = '/usr/local/lib/postgresql:/home/my_project/lib:$libdir' ...@@ -1784,12 +1784,13 @@ dynamic_library_path = '/usr/local/lib/postgresql:/home/my_project/lib:$libdir'
Specifies the amount of memory to be used by internal sorts and Specifies the amount of memory to be used by internal sorts and
hashes before switching to temporary disk files. The value is hashes before switching to temporary disk files. The value is
specified in kilobytes, and defaults to 1024 kilobytes (1MB). specified in kilobytes, and defaults to 1024 kilobytes (1MB).
Note that for a complex query, several sorts and/or hashes might be Note that for a complex query, several sorts might be running in
running in parallel, and each one will be allowed to use as much parallel, and each one will be allowed to use as much memory as
memory as this value specifies before it starts to put data into this value specifies before it starts to put data into temporary
temporary files. Also, each running backend could be doing one files. Also, each running backend could be doing one or more
or more sorts simultaneously, so the total memory used could be sorts simultaneously, so the total memory used could be many
many times the value of <varname>SORT_MEM</varname>. times the value of <varname>SORT_MEM</varname>. Sorts are used
by ORDER BY, merge joins, and CREATE INDEX.
</para> </para>
</listitem> </listitem>
</varlistentry> </varlistentry>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment