add index value for saving