mirror of
https://github.com/postgres/postgres.git
synced 2025-07-30 11:03:19 +03:00
Remove hstore's text => text operator.
Since PostgreSQL 9.0, we've emitted a warning message when an operator named => is created, because the SQL standard now reserves that token for another use. But we've also shipped such an operator with hstore. Use of the function hstore(text, text) has been recommended in preference to =>(text, text). Per discussion, it's now time to take the next step and stop shipping the operator. This will allow us to prohibit the use of => as an operator name in a future release if and when we wish to support the SQL standard use of this token. The release notes should mention this incompatibility. Patch by me, reviewed by David Wheeler, Dimitri Fontaine and Tom Lane.
This commit is contained in:
@ -119,13 +119,6 @@ key => NULL
|
||||
<entry><literal>{"z","x"}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><type>text</> <literal>=></> <type>text</></entry>
|
||||
<entry>make single-pair <type>hstore</></entry>
|
||||
<entry><literal>'a' => 'b'</literal></entry>
|
||||
<entry><literal>"a"=>"b"</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><type>hstore</> <literal>||</> <type>hstore</></entry>
|
||||
<entry>concatenate <type>hstore</>s</entry>
|
||||
@ -224,14 +217,6 @@ key => NULL
|
||||
</para>
|
||||
</note>
|
||||
|
||||
<note>
|
||||
<para>
|
||||
The <literal>=></> operator is deprecated and may be removed in a
|
||||
future release. Use the <literal>hstore(text, text)</literal> function
|
||||
instead.
|
||||
</para>
|
||||
</note>
|
||||
|
||||
<table id="hstore-func-table">
|
||||
<title><type>hstore</> Functions</title>
|
||||
|
||||
@ -455,7 +440,7 @@ CREATE INDEX hidx ON testhstore USING HASH (h);
|
||||
<para>
|
||||
Add a key, or update an existing key with a new value:
|
||||
<programlisting>
|
||||
UPDATE tab SET h = h || ('c' => '3');
|
||||
UPDATE tab SET h = h || hstore('c', '3');
|
||||
</programlisting>
|
||||
</para>
|
||||
|
||||
|
Reference in New Issue
Block a user