Documentation Prolog Predicate Reference builtin retract/1


Delete term from Prolog database.


retract( +clause )

retract(Clause) is true if there's at least one dynamic predicate in the database with the clause Clause. It has for side effect the removal of that dynamic predicate. Important: even if all the clauses of a certain predicate have been deleted using retract, the predicate can still be found using current_predicate/1.