Fixed the timestamp problem in residual tables