properly records disk offset in sqlite database