Re: hstores in pl/python - Mailing list pgsql-hackers

From Robert Haas
Subject Re: hstores in pl/python
Date
Msg-id AANLkTinVMVC9hzZwZpUmrNdYGyz-Hb=8xm-pipja12Oa@mail.gmail.com
Whole thread Raw
In response to Re: hstores in pl/python  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
2010/12/14 Tom Lane <tgl@sss.pgh.pa.us>:
> Robert Haas <robertmhaas@gmail.com> writes:
>> On Tue, Dec 14, 2010 at 11:51 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>>> If the element values all have to be the same type, you've
>>> basically got hstore.
>
>> Not exactly, because in hstore all the element values have to be,
>> specifically, text.  Having hstores of other kinds of objects would,
>> presumably, be useful.
>
> Maybe, but I'm sure they'd have far less application than hstore.
> There's a reason why that's based on text and not some other type ...

Sure.  You can smash anything to a string, and it's often a very
practical way to go, though not always.

I am not necessarily expressing any interest in building such a
facility, just pointing one way that it might hypothetically have an
advantage over hstore.  Whether it's worth pursuing is another
question.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


pgsql-hackers by date:

Previous
From: Pavel Stehule
Date:
Subject: Re: hstores in pl/python
Next
From: Oleg Bartunov
Date:
Subject: Re: hstores in pl/python