| From: | Andrew Chernow <ac(at)esilo(dot)com> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | Merlin Moncure <mmoncure(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
| Subject: | Re: change oid of a pg_type |
| Date: | 2009-04-11 21:59:04 |
| Message-ID: | 49E112A8.8000306@esilo.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Tom Lane wrote:
> Andrew Chernow <ac(at)esilo(dot)com> writes:
>> Tom Lane wrote:
>>> Merlin Moncure <mmoncure(at)gmail(dot)com> writes:
>>>> Is there any way to adjust the oid of an already created pg_type
>>> No.
>
>> Then why are oids sent in some type's external binary format?
>
> How is that related?
>
Well, the format is called "external", yet the oid is internal. It seem
like a contradiction. Maybe I'm being to literal but i think external
format should present an identifier other servers can understand/map.
>> If you
>> can't fix oids, external format is useless to the outside world.
>
> You have to be prepared to find out what type the OID belongs to.
> There's at least one client library (maybe JDBC) that maintains
> a cache of a SELECT from pg_type for exactly this purpose. Most
>
Yeah, libpqtypes looks them up by schema.name as one registers them,
PQregisterTypeHandler. Although this works, it feel more like a work
around. I think it would be cleaner if a dns-like resolution was not
required.
Andrew
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Abhijit Menon-Sen | 2009-04-11 23:04:38 | Re: Allow COMMENT ON to accept an expression rather than just a string |
| Previous Message | Tom Lane | 2009-04-11 21:21:59 | Re: change oid of a pg_type |