You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello. Could you assist on an exception I got while playing with clara-rules?
I'm trying to make a simple rule that calculates patient's age and a query which retrieve patients older than certain age. When I run (mk-session 'clara.example) I get an exception which says I have Unbound variables: #{?age} in my query. I don't understand, why is it unbound if it's passed as a parameter.
The reason for this behavior comes down to how Clara "executes" queries, or rather doesn't execute queries.
Rather than having a separate underlying construct for queries, Clara simply sees queries as rules without a RHS.
When a session is queried, rather than running logic for a query, instead Clara is simply asking "memory":
For this value(parameter/s), what satisfied this rule with these bindings?
To support the pattern above, Clara would have to somehow maintain all constraints with references to parameters and then upon request, apply the constraints after the initial facts were returned from memory.
Uh oh!
There was an error while loading. Please reload this page.
Hello. Could you assist on an exception I got while playing with clara-rules?
I'm trying to make a simple rule that calculates patient's age and a query which retrieve patients older than certain age. When I run
(mk-session 'clara.example)
I get an exception which says I have Unbound variables: #{?age} in my query. I don't understand, why is it unbound if it's passed as a parameter.The text was updated successfully, but these errors were encountered: