From: | Kris Jurka <books(at)ejurka(dot)com> |
---|---|
To: | Dave Cramer <pg(at)fastcrypt(dot)com> |
Cc: | Thor Michael Støre <thormichael(at)gmail(dot)com>, "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: Finding exact column type via java.sql.ResultSetMetaData |
Date: | 2013-02-14 17:11:31 |
Message-ID: | alpine.BSO.2.00.1302141206480.23041@leary.csoft.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
On Thu, 14 Feb 2013, Dave Cramer wrote:
> Yes, you are correct. The backend does not provide that information
>
No, the backend does provide the OID of the returned column type. So
internally we can tell the difference between the two types in different
schemas. The issue is how to return this information to the user.
ResultSetMetaData.getColumnTypeName doesn't have a corresponding
getColumnTypeSchema so we'd have to qualify the returned value. The
javadoc says we should in certain circumstances:
Returns:
type name used by the database. If the column type is a user-defined
type, then a fully-qualified type name is returned.
I'm concerned that doing this would break things for more users than it
would help because different types with the same name is a rarity. So
we'd probably need an option to enable/disable this.
Kris Jurka
From | Date | Subject | |
---|---|---|---|
Next Message | dmp | 2013-02-14 17:16:42 | Re: rounded brackets in prepared statement |
Previous Message | Dave Cramer | 2013-02-14 17:00:15 | Re: Finding exact column type via java.sql.ResultSetMetaData |