email:
i am trying to do some testing with sequence identifier generators, so i was going to use HSQLDB, since it now supports sequences (and since oracle on my laptop eats up 300M of my memory just by cranking it up). so i notice that the hsqldb dialect does not support sequences. so my question is can you give me a 10-line idiot guide on what i'd do if i want to 'upgrade' the dialect for sequences?
while i have your eyes, i'll pose the underlying question. i am mapping an oracle database that is being replicated. to guarantee uniqueness, the dba has a scheme where the PK for every table is a composite of a surrogate key )from a sequence) and a "site_id" (which is the name of the site where the record was first created). from what i can tell, from what you taught me (so if i am wrong some of the burden is obviously on you), i have a couple of choices (and trying to convince him to partition the id space has been tried and failed):
1) use "assigned" for the id generation. for this i'd have to query the oracle db for the next sequence and build my PK from that - i don't like this b/c it puts some JDBC code in my nice hibernate ORM
2) roll my own IdentifierGenerator, which would basically extend the hibernate SequenceGenerator and add my site thingy.
so what i am really trying to do is to implement #2, which is why i need to have HSQLDB support sequences (i don't think derby does sequences).