Re: hstore ==> and deprecate =>

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: hstore ==> and deprecate =>
Дата
Msg-id 13160.1276291414@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: hstore ==> and deprecate =>  (Joseph Adams <joeyadams3.14159@gmail.com>)
Ответы Re: hstore ==> and deprecate =>  (Merlin Moncure <mmoncure@gmail.com>)
Re: hstore ==> and deprecate =>  ("David E. Wheeler" <david@kineticode.com>)
Список pgsql-hackers
Joseph Adams <joeyadams3.14159@gmail.com> writes:
> To repeat an earlier question (which was in turn repeating an earlier
> question), would it be possible to do one of these, yielding '
> "key"=>"this", "key2"=>"that" '::hstore  :

> hstore(key := 'this', key2 := 'that')
> hstore(key => 'this', key2 => 'that')
> hstore(row('this' AS key, 'that' AS key2))

The last of those is probably the easiest to get to.  We already have
hstore_from_record:

contrib_regression=# select hstore(row('this', 'that'));              hstore           
----------------------------"f1"=>"this", "f2"=>"that"
(1 row)

and the only thing lacking is an easy way to specify the column names
associated with the anonymous record type.  Extending the ROW()
construct with AS labels as suggested above might be a reasonable way.
        regards, tom lane


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Joseph Adams
Дата:
Сообщение: Re: hstore ==> and deprecate =>
Следующее
От: Josh Berkus
Дата:
Сообщение: Re: Proposal for 9.1: WAL streaming from WAL buffers