Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

HSQL db for JPA: auto incremented for a regular column

 
H Paul
Ranch Hand
Posts: 471
4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is just a regular column that I want to have it auto incremented



After loading data, the NUMBER is always zero.

Am I missing something or doing something wrong or is HSQL db sql syntax incorrect?
 
James Sutherland
Ranch Hand
Posts: 553
 
H Paul
Ranch Hand
Posts: 471
4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
0. Thanks, James.

1. From
HyperSQL User Guide
HyperSQL Database Engine (HSQLDB) 2.2


2. Below is OK. Nothing unusual.



3. What I want is NOT an ID, rather a regular colum with auto-incremented.
This is OK by point 1. That's if we create using DDL itself.
But below is not OK. Could there be something else?


 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic