Release previous savepoints to fix "out of shared memory" errors.

It seems that PostgreSQL may not destroy previous savepoints with the same name. This can lead to an "out of shared memory" when updating a large (>10k) number of records.
This explicitly releases the savepoint before recreating it.

--HG--
branch : dreispt/release-previous-savepoints
Merge branch 'release-previous-savepoints'

why this merge is necessary,