You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-user@db.apache.org by "Dag H. Wanvik" <da...@oracle.com> on 2011/02/01 21:38:57 UTC

Re: Update sequence

Brett Wooldridge <br...@gmail.com> writes:

> We are currently using Hibernate with a table managed sequence scheme
> (javax.persistence.GenerationType.TABLE), but now that Derby supports
> Sequences we are considering migrating to real sequences
> (javax.persistence.GenerationType.SEQUENCE).
>
> One question we have is, is it possible to ALTER a sequence?  From
> what I've seen, the answer is currently no, but I thought I would ask
> here just in case.

It is not supported. You would have to do a DROP + a new CREATE. Note
that a new sequence can take a START WITH value, though.

Thanks,
Dag