Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FILTER isTemporal #154

Merged
merged 4 commits into from
Oct 26, 2020
Merged

FILTER isTemporal #154

merged 4 commits into from
Oct 26, 2020

Conversation

rogerlucena
Copy link
Contributor

This PR comes to add support for the isTemporal FILTER function in BadWolf, as detailed in #129. It also comes to help resolving what was requested by #115.

To illustrate its implementation on the driver side, this PR also adds support for this FILTER in the volatile OSS driver (in memory.go).

Now, the user can write queries like:

SELECT ?p, ?o
FROM ?test
WHERE {
    /u<peter> ?p ?o .
    FILTER isTemporal(?p)
};

That would return only rows for which the predicate ?p is temporal. For other examples of queries have a look at the newly added tests in planner_test.go.

This FILTER function also works for object bindings in the clause, along with predicate aliases and object aliases too.

@rogerlucena rogerlucena marked this pull request as ready for review October 16, 2020 15:08
@thiagovas thiagovas merged commit 73451a9 into google:master Oct 26, 2020
@rogerlucena rogerlucena deleted the filter-isTemporal branch October 26, 2020 13:43
@rogerlucena rogerlucena mentioned this pull request Nov 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants