datalog translation