Re: Data in table changed?

From: Stephen Frost <sfrost(at)snowman(dot)net>
To: Thomas Holmgren <thm(at)regnecentralen(dot)dk>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Data in table changed?
Date: 2004-03-02 14:11:50
Message-ID: 20040302141150.GZ7060@ns.snowman.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

* Thomas Holmgren (thm(at)regnecentralen(dot)dk) wrote:
> I have a large number of clients synchronizing with a central database.
> The clients update their local data by polling the database for changes
> at fixed intervals. I need an efficient way of determining if data in a
> table has been changed (either updated, deleted or inserted). Can this
> be achieved without scanning the tables using expensive SQL? (my tables
> are _big_!) Is there some way to get a "time for last update" for a
> specific table? Or something similar I can use?

I would guess that you could create a trigger for the tables which
updates a seperate (small) table with the last-changed timestamp.

Stephen

In response to

Browse pgsql-general by date

  From Date Subject
Next Message scrappy 2004-03-02 14:20:21 My photoalbum
Previous Message Thomas Holmgren 2004-03-02 14:04:23 Data in table changed?