minor changes, incomplete find and insert