Read data from WAL

From: Baldur Þór Emilsson <baldur(at)baldur(dot)biz>
To: pgsql-general(at)postgresql(dot)org
Subject: Read data from WAL
Date: 2013-07-15 12:45:54
Message-ID: CAMqGZ2zgyAa3KzH-_qejVBfbHJ+-hNSO+nXJ6OFH+ibHeewzxA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I have been looking into the WAL to know if there is any way to read the
data contained in it. I know that it stores binary data that is applied
directly to the files in the Postgres cluster. I would like to get the
"real" data, like it is written in the SQL queries, instead of the binary
data.

Are there any projects or standard procedures for reading the data from the
WAL to get a change log for the database (or without the WAL, using some
other method)? I have searched for information about this quite thoroughly
without luck, so I thought I'd try asking here before I started to patch
Postgres :)

About the project I'm working on: it's a project for my master thesis at
the University of Iceland. I'm trying to build a framework for quick
creation of development and testing databases in Postgres. It's still in
early stages but the idea is to create the schema first and use views that
fetch the data as it is needed. I run a database in the middle of dev and
master that stores the history of the data in master, that way I can fetch
data for dev using the state of master as it was when dev was created. To
that end I need to monitor changes in master, and I would like to read the
WAL for that as it requires no changes to the master DB (unlike triggers).

Regards,
Baldur Þór

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Satoshi Nagayasu 2013-07-15 12:58:51 Re: Read data from WAL
Previous Message Vincenzo Romano 2013-07-15 11:50:22 Re: