Package com.microsoft.sqlserver.jdbc

## Class SQLServerSavepoint

- java.lang.Object
- - com.microsoft.sqlserver.jdbc.SQLServerSavepoint

All Implemented Interfaces:
  `Savepoint`

    public final class SQLServerSavepoint
    extends Object
    implements Savepoint

SQLServerSavepoint implements JDBC 3.0 savepoints. A savepoint is checkpoint to which a transaction can be rolled back. Savepoints are defined relative to a connection.

The API javadoc for JDBC API methods that this class implements are not repeated here. Please see Sun's JDBC API interfaces javadoc for those details.

### Constructor Summary

Constructors
`SQLServerSavepoint​(SQLServerConnection con, String sName)` Create a new savepoint

### Method Summary

All Methods Instance Methods Concrete Methods
`String` `getLabel()` Get the savepoint label
`int` `getSavepointId()`
`String` `getSavepointName()`
`boolean` `isNamed()` Checks if the savepoint label is null

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### SQLServerSavepoint

    public SQLServerSavepoint​(SQLServerConnection con,
                              String sName)

Create a new savepoint

Parameters:
  `con` - the connection
  `sName` - the savepoint name

### Method Detail

#### getSavepointName

    public String getSavepointName()
                            throws SQLServerException

Specified by:
  `getSavepointName` in interface `Savepoint`
Throws:
  `SQLServerException`

#### getLabel

    public String getLabel()

Get the savepoint label

Returns:
  the name

#### isNamed

    public boolean isNamed()

Checks if the savepoint label is null

Returns:
  true is the savepoint is named. Otherwise, false.

#### getSavepointId

    public int getSavepointId()
                       throws SQLServerException

Specified by:
  `getSavepointId` in interface `Savepoint`
Throws:
  `SQLServerException`