---
name: "mdb_txn"
section: "3"
platform: "linux"
package: "lmdb-doc"
version: "0.9.31-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/mdb_txn"
---

# mdb\_txn(3)

Transaction Flags

## NAME

mdb\_txn - Transaction Flags

## SYNOPSIS

### Macros

\#define **MDB\_TXN\_BEGIN\_FLAGS**   **MDB\_RDONLY**\
 \#define **MDB\_TXN\_RDONLY**   **MDB\_RDONLY**\
 \#define **MDB\_TXN\_WRITEMAP**   **MDB\_WRITEMAP**\
 \#define **MDB\_TXN\_FINISHED**   0x01\
 \#define **MDB\_TXN\_ERROR**   0x02\
 \#define **MDB\_TXN\_DIRTY**   0x04\
 \#define **MDB\_TXN\_SPILLS**   0x08\
 \#define **MDB\_TXN\_HAS\_CHILD**   0x10\
 \#define **MDB\_TXN\_BLOCKED**   (**MDB\_TXN\_FINISHED**\|**MDB\_TXN\_ERROR**\|**MDB\_TXN\_HAS\_CHILD**)\

## Detailed Description

## Macro Definition Documentation

### #define MDB\_TXN\_BEGIN\_FLAGS MDB\_RDONLY

**mdb\_txn\_begin()** flags

### #define MDB\_TXN\_RDONLY MDB\_RDONLY

read-only transaction

### #define MDB\_TXN\_WRITEMAP MDB\_WRITEMAP

copy of **MDB\_env** flag in writers

### #define MDB\_TXN\_FINISHED 0x01

txn is finished or never began

### #define MDB\_TXN\_ERROR 0x02

txn is unusable after an error

### #define MDB\_TXN\_DIRTY 0x04

must write, even if dirty list is empty

### #define MDB\_TXN\_SPILLS 0x08

txn or a parent has spilled pages

### #define MDB\_TXN\_HAS\_CHILD 0x10

txn has an **MDB\_txn**.mt\_child

### #define MDB\_TXN\_BLOCKED (MDB\_TXN\_FINISHED\|MDB\_TXN\_ERROR\|MDB\_TXN\_HAS\_CHILD)

most operations on the txn are currently illegal

## Author

Generated automatically by Doxygen for LMDB from the source code.
