On Apr 29, 2006, at 4:18 PM, Robby Russell wrote:
On Apr 29, 2006, at 12:49 PM, Dan Black wrote:
Hello, everybody!
How can I view deleted records in table?
SELECT * FROM recycle_bin;
;-)
Just kidding... once you delete your records... they are gone.
That's.... not true.
Deleted (or modified) records don't go away until the space
they use is recycled by the VACUUM command.
However, there's no support in postgresql for any sort of
"time travel", including viewing deleted tuples. The data
is there on the disk, but there is no clean way to view it
via the database.
It's certainly not something a DBA should even think about
(outside of security issues) but deleted tuples are available
in a forensics situation, as long as vacuum hasn't been run.
Cheers,
Steve