delete command improved, search function expanded