Generalized Production Rules as a Basis for Integrating Active and Deductive Databases