| From: | Craig Ringer <craig(at)postnewspapers(dot)com(dot)au> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | rawi <only4com(at)web(dot)de>, pgsql-sql(at)postgresql(dot)org |
| Subject: | Re: Hibernate, web application and only one sequence for all primary keys |
| Date: | 2009-09-18 02:01:34 |
| Message-ID: | 4AB2E9FE.9080006@postnewspapers.com.au |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-sql |
Tom Lane wrote:
> rawi <only4com(at)web(dot)de> writes:
>> Grails/Hibernate wishes per default one sequence for all tables-PKs and all
>> PKs as BigInt.
>
> Redesign that software; this is fundamentally broken and stupid.
It's a pretty silly default, but it's clearly intended for simple /
small databases. In any real database you'll be using one sequence per
generated PK. I've had no problems with this with Hibernate, and am a
bit puzzled that the OP is trying to fit their DB to Hibernate rather
than doing the trivial configuration required to get Hibernate to fit
the DB.
The Hibernate documentation is pretty good, and covers this sort of
thing well.
--
Craig Ringer
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Adrian Klaver | 2009-09-18 02:40:05 | Re: Rules, functions and RETURNING |
| Previous Message | Kenneth Marshall | 2009-09-17 17:39:59 | Re: extracting from epoch values in pgsql |