This paper presents a new approach to handling large fact bases for artificial intelligence and applies it to the design of an interface between databases and Prolog. It extends a previous paper by the authors, which was based on preanalysis. The interface acts as a loading mechanism. The authors introduce tracers in order to formalize the meta-knowledge about the structure of formulas and handle the loading of data from secondary storage during program execution more efficiently. Tracers can be partially ordered and this ordering can be used both to load the subsumed (i.e., the common) part first and, later on, to handle exceptions like negative facts. The authors implement the method as a prototype and show its effectiveness by means of comparisons. The method is new and seems to be applicable to general query and transaction handling in databases and knowledge bases as well, especially in Prolog-like environments.