delete function modified for invalid_itemcodes
clearstock function modified for null fields