As Herve is mentioning, this is normal behavior and it happens on both SQL Azure and SQL Server.
The IDENTITY property will guarantee unique subsequent values on a column inside a single database, but it cannot guarantee the values to be consecutive. There are multiple scenarios that can lead to gaps between the values. One of them is the one mentioned
by you, with an error happening during the insert. Another is caused by deletions. Yet another is caused by transaction rollbacks (described
here).
If you need to make sure that the values inside a column are consecutive, then you will need to implement a custom mechanism for that. Just be aware that such a mechanism is prone to performance and locking issues.
Read my technical blog: ducons.com/blog | Connect with me on twitter:
@fdumitrescu