Wrote data insertion code.