↑↓ select ↵ open ⌫ change scope Open full search

PG.CENTER connects PostgreSQL documentation, reference, and ecosystem knowledge. Maintained by Pigsty.

Functions / System Administration Functions

pg_last_wal_replay_lsn

Read the PG 18 manual

Returns the last write-ahead log location that has been replayed during recovery.

Reading PG 18current·documented in 11 of 27 versions, 10 to 20

Signatures & examples

pg_last_wal_replay_lsn () → pg_lsn
Returns the last write-ahead log location that has been replayed during recovery. If recovery is still in progress this will increase monotonically. If recovery has completed then this will remain static at the location of the last WAL record applied during recovery. When the server has been started normally without recovery, the function returns NULL.
Version history 2
  1. 12 → 13 changed
  2. 9.6 → 10 added

Definition snapshot: b7bd9cda · English manual source