Datalog Rules, Programs & Queries
A pure datalog rule = first-order horn clause with a positive literal
ws(Date,From,To,Pilot,Aircraft)
=> flight(Airline, Flight_no, From, To) &
schedule(Airline, Flight_no, Date, Pilot, Aircraft)
A datalog program is a set of datalog rules.
A program with a single rule is a conjunctive query.
We distinguish EDB predicates and IDB predicates
- EDB’s are stored in the database, appear only in the bodies
- IDB’s are intensionally defined, appear in both bodies and heads.