store ts in seconds in DB