diff --git a/contrib/hstore/hstore.sql.in b/contrib/hstore/hstore.sql.in index fb39967866c..3fa3af3ee20 100644 --- a/contrib/hstore/hstore.sql.in +++ b/contrib/hstore/hstore.sql.in @@ -1,4 +1,4 @@ -/* $PostgreSQL: pgsql/contrib/hstore/hstore.sql.in,v 1.8 2007/11/13 04:24:28 momjian Exp $ */ +/* $PostgreSQL: pgsql/contrib/hstore/hstore.sql.in,v 1.8.2.1 2010/06/22 11:36:36 rhaas Exp $ */ -- Adjust this setting to control where the objects get created. SET search_path = public; @@ -129,6 +129,12 @@ RETURNS hstore AS 'MODULE_PATHNAME' LANGUAGE C IMMUTABLE; +-- For forward compatibility with PostgreSQL >= 9.0 +CREATE OR REPLACE FUNCTION hstore(text,text) +RETURNS hstore +AS 'MODULE_PATHNAME', 'tconvert' +LANGUAGE C IMMUTABLE; -- not STRICT + CREATE OPERATOR => ( LEFTARG = text, RIGHTARG = text, diff --git a/contrib/hstore/uninstall_hstore.sql b/contrib/hstore/uninstall_hstore.sql index d9e08927a5e..ae2676a1b05 100644 --- a/contrib/hstore/uninstall_hstore.sql +++ b/contrib/hstore/uninstall_hstore.sql @@ -1,4 +1,4 @@ -/* $PostgreSQL: pgsql/contrib/hstore/uninstall_hstore.sql,v 1.6 2007/11/13 04:24:28 momjian Exp $ */ +/* $PostgreSQL: pgsql/contrib/hstore/uninstall_hstore.sql,v 1.6.2.1 2010/06/22 11:36:36 rhaas Exp $ */ -- Adjust this setting to control where the objects get dropped. SET search_path = public; @@ -26,6 +26,7 @@ DROP FUNCTION hs_concat(hstore,hstore); DROP FUNCTION hs_contains(hstore,hstore); DROP FUNCTION hs_contained(hstore,hstore); DROP FUNCTION tconvert(text,text); +DROP FUNCTION hstore(text,text); DROP FUNCTION akeys(hstore); DROP FUNCTION avals(hstore); DROP FUNCTION skeys(hstore); diff --git a/doc/src/sgml/hstore.sgml b/doc/src/sgml/hstore.sgml index a3d82c970c6..911e46f2743 100644 --- a/doc/src/sgml/hstore.sgml +++ b/doc/src/sgml/hstore.sgml @@ -1,4 +1,4 @@ - + hstore @@ -134,6 +134,14 @@ datatypes!) + + + The => operator is deprecated and may be removed in a + future release. Use the hstore(text, text) function + instead. + + + <type>hstore</> Functions @@ -149,6 +157,14 @@ + + hstore(text, text) + hstore + make single-item hstore + hstore('a', 'b') + "a"=>"b" + + akeys(hstore) text[]