You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jena.apache.org by "Andy Seaborne (JIRA)" <ji...@apache.org> on 2016/07/28 11:03:20 UTC
[jira] [Resolved] (JENA-1216) xsd:integer literals with
leading/trailing whitespace not handled as values.
[ https://issues.apache.org/jira/browse/JENA-1216?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andy Seaborne resolved JENA-1216.
---------------------------------
Resolution: Fixed
> xsd:integer literals with leading/trailing whitespace not handled as values.
> ----------------------------------------------------------------------------
>
> Key: JENA-1216
> URL: https://issues.apache.org/jira/browse/JENA-1216
> Project: Apache Jena
> Issue Type: Bug
> Components: ARQ
> Affects Versions: Jena 3.1.0
> Reporter: Andy Seaborne
> Assignee: Andy Seaborne
> Fix For: Jena 3.1.1
>
>
> This throws an exception:
> {noformat}
> Node n = SSE.parseNode("' 1'^^xsd:integer") ;
> NodeValue.makeNode(n) ;
> {noformat}
> Once you know that, it's quite easy to cause the problem from SPARQL:
> {noformat}
> PREFIX : <http://example/> .
> PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
> # whitespace in the lexical form.
> :s :p " 1"^^xsd:integer .
> {noformat}
> and any query with a FILTER that uses the value of the literal.
> {noformat}
> SELECT *
> WHERE {
> ?s ?p ?o .
> FILTER ( ?o != 9 )
> }
> {noformat}
> It affects xsd:integer and derived types, not other datatypes.
> Because Turtle short form for integers does not generate this situation, it is masked to some extent.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)