Current problem with GENERATED BY DEFAULT is that once it generates a value that is already present in the table, NONE of the future inserts can succeed. I can understand the current insert failing when there is a duplicate value, but preventing all future inserts (fails because they keep generating the same value, I suppose) seems wrong.

I would be happy if Derby can consume identity values even if current insert statement fails. For this case, some insert statements may fail when they generate a value that is already present. But subsequent inserts should pass.

Satheesh

Mamta Satoor wrote:
Hi,
 
I was looking at Derby-359 and was wondering what was the exact scope of this bug. Are we saying that when system generates a value for GENERATED BY DEFAULT column, it should check if the next value it plans to insert is already used and if yes, then it should skip that value and try to use the next value and continue this until it finds an unused value for the column?
 
Thanks,
Mamta

Reply via email to