Hi Michael,
What you describe is actually in the direction I was thinking about.
Instead of Prolog, I was actually more inclined to try out something
like Datalog, because it is decidable.
The one thing that doesn't seem to neatly fit Datalog and with that
Prolog, is Neo4j's relationship properties.
Let me give you an example of what I would like to achieve.
Suppose we have a database with persons and organizations, where both
can have a start and end date, and we have relationships between those
persons and organizations denoting the position that person held
within that organization, also potentially with a start and an end
date.
Now we want the following rules to apply.
If an end date for the position (a relationhip property) is given then
the end date of that position is the value of that property.
If no end date for the position is given then the minimum of the end
date of the organization and the end date of the person is to be
returned.
If neither the position nor the organization, nor the person has an
end date, no value should be returned.
So instead of reasoning about node-rel-node we actualyy reason about:
node-property
node-rel-property
node-rel-node-property
So where a naive Prolog/Datalog implementation would assume our
variables bind to nodes, we need to bind variables to either nodes or
relationships.
On Mar 13, 1:23 am, Michael Hunger <
michael.hun...@neotechnology.com>
wrote: