From: | Dave Cramer <pg(at)fastcrypt(dot)com> |
---|---|
To: | Tom Dunstan <pgsql(at)tomd(dot)cc> |
Cc: | Andreas Joseph Krogh <andreak(at)officenet(dot)no>, "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: [HACKERS] JPA + enum == Exception |
Date: | 2013-07-05 09:57:42 |
Message-ID: | CADK3HHKjG+31Dnj9DxV2nDqTGq4_08y+Y3F08NE-AaPntgZtEg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-jdbc |
I would think setObject should respect stringtype=unspecified. So I would
be willing to accept this as a solution
Dave Cramer
dave.cramer(at)credativ(dot)ca
http://www.credativ.ca
On Fri, Jul 5, 2013 at 5:47 AM, Tom Dunstan <pgsql(at)tomd(dot)cc> wrote:
> Hi Andreas
>
> On 5 July 2013 18:51, Andreas Joseph Krogh <andreak(at)officenet(dot)no> wrote:
>
>> I've been using Hibernate for years with mapping Enums to varchar-columns
>> which works fine. Remember to map them with
>>
>
> I'm not trying to map them to varchar columns - I'm trying to map them to
> columns with postgresql enum types as created by CREATE TYPE, see e.g.
> http://www.postgresql.org/docs/9.2/static/datatype-enum.html. The
> built-in enum types are designed for that purpose, and perform better and
> more safely than using varchars.
>
> Mapping java enums to a typesafe and efficient version in the db was the
> main reason I did the work to add native enums to postgresql in the first
> place - I haven't had a chance to use it recently, and I'm a bit
> disappointed that it doesn't work out of the box. So I want to fix up
> whatever parts of the stack are in the way of making that work.
>
> Cheers
>
> Tom
>
From | Date | Subject | |
---|---|---|---|
Next Message | Dean Rasheed | 2013-07-05 10:59:40 | Re: WITH CHECK OPTION for auto-updatable views |
Previous Message | Andreas Joseph Krogh | 2013-07-05 09:55:57 | Re: [HACKERS] JPA + enum == Exception |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Dunstan | 2013-07-07 04:09:16 | Re: [HACKERS] JPA + enum == Exception |
Previous Message | Andreas Joseph Krogh | 2013-07-05 09:55:57 | Re: [HACKERS] JPA + enum == Exception |