comparison - Compare values as doubles in a JCR-SQL2 query -
i trying compare jcr node's string properties double value in jcr-sql2. comparing values strings.
for example:
select * [nodex] x x.propertyy <= 20.50 here propertyy string in definition.
i tried case still not work. can compare double without changing property definition?
standard jcr-sql2 has cast(value double) expression, unfortunately can used on right-hand side of expression. yes, jcr-sql2 not flexible normal sql.
to knowledge, there not valid standard way convert property value double before running comparison. if cast double value string, you'll lexicographical comparison -- of course won't useful.
i'm not sure other implementations, modeshape convert property value double when property residual property, since residual property has no definition , therefore not type. it's quite other implementations not behave this.
Comments
Post a Comment