Project

General

Profile

Bug #136

IntervalConstraintDescriptor converts all bounds to xsd:double

Added by Alex Hall - over 15 years ago. Updated over 15 years ago.

Status:
New
Priority:
Urgent
Assignee:
Category:
Mulgara
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:

Description

The Bounds object used by IntervalConstraintDescriptor to store the upper and lower bounds of a constraint stores the bounds as doubles. The IntervalConstraintDescriptor.resolve(...) method always uses SPDouble objects constructed from these bounds when slicing the stringpool. This makes it impossible to compare on datatypes derived from xsd:decimal (i.e. xsd:int, xsd:long, etc).

For instance, the following sequence of TQL commands produces no results:

create <rmi://localhost/server1#test>;
insert <test:foo> <rdf:value> '1'^^<http://www.w3.org/2001/XMLSchema#int>
   into <rmi://localhost/server1#test>;
select $x from <rmi://localhost/server1#test> where 
   $x <mulgara:gt> '0'^^<http://www.w3.org/2001/XMLSchema#int> in <sys:xsd>;
#1

Updated by ronald - over 15 years ago

I believe XSDResolver.resolve also needs to be fixed in a similar
way in order for this query to work, as it always does a range search
on the string-pool using doubles.

Also available in: Atom PDF