Solved problem with insertion of data with range