Double type problem!

Hello, I just encouter a probme to sum() or avg() the number which is double or float .


{
for $m in document(“data/Admission.xml”)/Admission/Applicants/Applicant//UnderGPA
let $c := sum($m)
return

{$c}

}


if the tag has data type double like , 3.5 or 3.6. , the Quip will has the error below :

<quip:SystemError xmlns:quip=“http://namespaces.softwareag.com/tamino/quip/”>
quip:queryFile
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\Query20666.tmp
</quip:queryFile>
quip:message

</quip:message>
</quip:SystemError>
If the Grade contains only integer , then this query would be fine.

Deos that mean Quip does not support float type ???

Thank you .

generally the functions avg,sum,min,max work perfectly with floating numbers, e.g:

avg((294e-10,0,78e10,2.5,9,0,1.23))

works fine. The problem is something else.
In the example above float literals are used.
The values you have in your application
are actually unparsed character
data, which unfortunately the Quip
implementation tries to parse as integer values
for these functions. So you would need to
convert these character data into floats
explicitly (note you do not have any schema
information right now in quip). Unfortunately,
constructors for creating floats from Strings are
missing in the set of built-in functions in quip.

Thank you for noticing this. It will be fixed in
the next quip release, which will be out by end of
May.

Sven Eric