aboutsummaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorPeter Eisentraut <peter@eisentraut.org>2021-03-06 19:25:45 +0100
committerPeter Eisentraut <peter@eisentraut.org>2021-03-06 19:28:05 +0100
commitf9a0392e1cf36179c984f655a6589734b8dd7468 (patch)
tree72cf42d84a56ebc5cb99caa648bffe2c2110147a /doc/src
parent30b26dfac7db2fc76dafaa8a6c459871bfcd100e (diff)
downloadpostgresql-f9a0392e1cf36179c984f655a6589734b8dd7468.tar.gz
postgresql-f9a0392e1cf36179c984f655a6589734b8dd7468.zip
Add bit_xor aggregate function
This can be used as a checksum for unordered sets. bit_and and bit_or already exist. Author: Alexey Bashtanov <bashtanov@imap.cc> Reviewed-by: Ibrar Ahmed <ibrar.ahmad@gmail.com> Discussion: https://www.postgresql.org/message-id/flat/9d4582ae-ecfc-3a13-2238-6ab5a37c1f41@imap.cc
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/func.sgml27
1 files changed, 27 insertions, 0 deletions
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml
index fee05619612..ece09699ef8 100644
--- a/doc/src/sgml/func.sgml
+++ b/doc/src/sgml/func.sgml
@@ -19227,6 +19227,33 @@ SELECT NULLIF(value, '(none)') ...
<row>
<entry role="func_table_entry"><para role="func_signature">
<indexterm>
+ <primary>bit_xor</primary>
+ </indexterm>
+ <function>bit_xor</function> ( <type>smallint</type> )
+ <returnvalue>smallint</returnvalue>
+ </para>
+ <para role="func_signature">
+ <function>bit_xor</function> ( <type>integer</type> )
+ <returnvalue>integer</returnvalue>
+ </para>
+ <para role="func_signature">
+ <function>bit_xor</function> ( <type>bigint</type> )
+ <returnvalue>bigint</returnvalue>
+ </para>
+ <para role="func_signature">
+ <function>bit_xor</function> ( <type>bit</type> )
+ <returnvalue>bit</returnvalue>
+ </para>
+ <para>
+ Computes the bitwise exclusive OR of all non-null input values.
+ Can be useful as a checksum for an unordered set of values.
+ </para></entry>
+ <entry>Yes</entry>
+ </row>
+
+ <row>
+ <entry role="func_table_entry"><para role="func_signature">
+ <indexterm>
<primary>bool_and</primary>
</indexterm>
<function>bool_and</function> ( <type>boolean</type> )