The quality of an answer to a database query can be enhanced by utilizing semantic knowledge such that an expert would use if he/she were to answer the query. A system capable of utilizing such expert knowledge in a deductive database paradigm is presented. A given query is reformulated to reduce the cost of evaluation, to generate a subset of answers in the shortest amount of time, and/or to generate the set of good answers. Semantic knowledge is represented by a set of Horn clauses where a number of special predicates are used. The situations in which certain knowledge becomes relevant to a query are defined, and a method of identifying these situations is given. The authors present the ways in which semantic knowledge can be used and a backtracking scheme for inaccurate knowledge.