added functions to delete fields and instances