Hi there,
I have a table in SQL Server that gets loaded with data, wiped out, reloaded, etc. many times during a single day. I'm using Hibernate to manage it, but am worried about the value of the primary key column increasing ad infinitum.
I noticed that by issuing a "truncate [tablename]" call to SQL Server, it actually resets the counter on the ID column. Is there an equivalent way to do this vis a vis Hibernate? If not, can I just call "truncate [tablename]" through Hibernate's session and assume that Hibernate will figure out that all of the objects have been deleted (as opposed to doing a delete where the HQL string is "from [class]")?
Thanks in advance.
Adam Rice
|