A framework for vacuuming temporal databases