Skip site navigation (1) Skip section navigation (2)

Re: BUG #4586: Supporting of Binary instead Bytea for Primary Keys

From: Miroslav Nachev <miro(at)space-comm(dot)com>
To: pgsql-bugs(at)postgresql(dot)org
Cc: Kris Jurka <books(at)ejurka(dot)com>
Subject: Re: BUG #4586: Supporting of Binary instead Bytea for Primary Keys
Date: 2008-12-17 22:33:42
Message-ID: 49497E46.70102@space-comm.com (view raw or flat)
Thread:
Lists: pgsql-bugs
I try to use it but I have the following exception:



java.lang.IllegalArgumentException: Unknown entity:
java.util.UUID

 at
org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:223)


 at
psqluuidtest.Main.persist(Main.java:33)

 at
psqluuidtest.Main.main(Main.java:25)



The NetBeans project
is attached.

The used driver is postgresql-8.4dev-700.jdbc4.





Miro.





Miroslav Nachev wrote:
Hi,



This is very good. Can you give me some idea how to use that
feature together with Hibernate JPA? Is there some special
annotation or ?





Regards,

Miro.



Kris Jurka wrote:





On Wed, 17 Dec 2008, Miroslav Nachev wrote:



Thank you very much. How can I map PostgreSQL UUID to
JPA Hibernate with

annotations? Serializable or BigInteger or byte[] or
java.util.UUID?





The server uuid type is already mapped to java.util.UUID in recent
JDBC driver versions:



http://archives.postgresql.org/pgsql-jdbc/2008-09/msg00102.php




Kris Jurka










Attachment: PsqlUuidTest.zip
Description: application/octet-stream (14.0 KB)
Attachment: unknown_filename
Description: text/html (1.8 KB)

In response to

Responses

pgsql-bugs by date

Next:From: Kris JurkaDate: 2008-12-17 22:52:04
Subject: Re: BUG #4586: Supporting of Binary instead Bytea for Primary Keys
Previous:From: Miroslav NachevDate: 2008-12-17 22:30:25
Subject: Re: BUG #4586: Supporting of Binary instead Bytea for Primary Keys

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group