Added Merge,Reset and fixed append logic