DbTxn::get_name()
Prev | Chapter 13. The DbTxn Handle | Next

## DbTxn::get_name()

    #include <db_cxx.h>

    int
    DbTxn::get_name(const char **namep);

The `DbTxn::get_name()` method returns the string associated with the transaction.

The `DbTxn::get_name()` method may be called at any time during the life of the application.

The `DbTxn::get_name()` method either returns a non-zero error value or throws an exception that encapsulates a non-zero error value on failure, and returns 0 on success.

### Parameters

#### namep

The `DbTxn::get_name()` method returns a reference to the string associated with the transaction in namep.

### Class

DbEnv, DbTxn

### See Also

Transaction Subsystem and Related Methods

Prev | Up | Next
DbTxn::discard() | Home | DbTxn::id()