# Restrictions on savepoints

Derby does not support savepoints within a trigger.

Derby does not release locks as part of the rollback to savepoint.

Table 1. JDBC 3.0 Savepoint Methods
Returns | Signature | Implementation Notes
--- | --- | ---
int | getSavepointId() | Throws SQLException if this is a named savepoint. Retrieves the generated ID for the savepoint that this Savepoint object represents.
String | getSavepointName() | Throws SQLException if this is an unnamed savepoint. Retrieves the name of the savepoint that this Savepoint object represents.

Parent topic: java.sql.Savepoint interface
Related concepts
Setting and rolling back to a savepoint
Releasing a savepoint
Rules for savepoints