Removing Clauses from the Database

This section briefly describes the predicates used to remove the clauses and/or properties of a predicate from the system.

Please note: Removing all of a predicate's clauses by retract/1 and/or erase/1 (see ref-mdb-rcd-efu) does not remove the predicate's properties (and hence its definition) from the system. The only way to completely remove a predicates clauses and properties is to use abolish/[1,2].


retract(C)
erase the first dynamic clause that matches C
retractall(H)
erase every clause whose head matches H
abolish(F)
abolish the predicate(s) specified by F
abolish(F,N)
abolish the predicate named F of arity N
erase(R)
erase the clause or recorded term (see ref-mdb-idb) with reference R