Hey, im creating a few linked tables and copying them into my h2 db - the 
problem im running into is when i try to recreate the indexes. I am hoping 
someone can shed some light:

Caused by: org.hibernate.HibernateException: The database returned no 
natively generated identity value

Ive tried creating a hibernate_sequence as well as setting up the indexes:

CREATE SEQUENCE hibernate_sequence;
CREATE TABLE IF NOT EXISTS table AS SELECT * FROM linked_table;             
      -- copy the data from the link
CREATE UNIQUE INDEX table_pkey  PRIMARY KEY ON table(id);                   
   -- try to create the index

These columns are not auto_increment because hibernate generally takes care 
of that. Is there a way to also get that behavior in my copied H2 db? I am 
still using hibernate on the h2 copy.

Thanks!

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/h2-database/-/iBX_LnaKR5IJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en.

Reply via email to