[
https://issues.apache.org/jira/browse/JENA-2013?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17247241#comment-17247241
]
Andy Seaborne commented on JENA-2013:
-------------------------------------
Hi Johannes,
Thank you for the report - it does look wrong.
The evaluator is supposed to treat {{xsd:dataTimeStamp}} as a derived type of
{{xsd:dateTime}}.
The {{qexpr}} tool evaluates an expression (with a few namespaces built-in)
This is a test case:
{noformat}
qexpr " '1999-10-26T19:32:52+00:00'^^xsd:dateTimeStamp >
'2000-01-01T00:00:00+00:00'^^xsd:dateTimeStamp ";
{noformat}
> Comparison for DateTimeStamp not working
> ----------------------------------------
>
> Key: JENA-2013
> URL: https://issues.apache.org/jira/browse/JENA-2013
> Project: Apache Jena
> Issue Type: Bug
> Components: Fuseki
> Affects Versions: Jena 3.14.0
> Environment: This example dataset with both xsd:dateTime and
> xsd:dateTimeStamp specified, loaded into Apache Jena Fuseki:
> {code:java}
> @prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
> @prefix ex: <http://example.org#> .
> ex:Foo ex:dateTime "2001-10-26T19:32:52+00:00"^^xsd:dateTime .
> ex:Foo ex:dateTimeStamp "2001-10-26T19:32:52+00:00"^^xsd:dateTimeStamp .
> {code}
> Reporter: Johannes Lipp
> Priority: Major
>
> *Summary:*
> The SPARQL query interface does handle greater/smaller than (< or >) for
> xsd:dateTime properly, but does not handle xsd:dateTimeStamp correctly.
>
> *Expected behavior:*
> Executing the following query in Fuseki returns one result, because [the docs
> say that xsd:dateTimeStamp is
> supported|https://jena.apache.org/documentation/query/xsd-support.html]:
> {code:java}
> PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>SELECT ?subject ?predicate
> ?object
> WHERE {
> ?subject ?predicate ?object .
>
> FILTER (?object > "1999-10-26T19:32:52+00:00"^^xsd:dateTimeStamp) .
> }
> LIMIT 25
> {code}
> *Actual behavior:*
> The query returns no results. Querying via equals (= 2001...) instead of
> greater (> 1999...) works. Also, replacing xsd:dateTimeStamp with
> xsd:dateTime works as expected - but the xsd:dateTimeStamp does not return
> anything.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)