From: Nick S. <nsi...@nu...> - 2021-01-26 05:06:01
|
Nevermind. User error. On 1/25/21 8:39 PM, Nick Sincaglia wrote: > I am calling a web service which returns a number in scientific > notation. I need to convert it to an integer. This should be simple > but I am not able to find a solution. > > When I run the below code in eXide, I get the correct answer of 46622388. > xquery version "3.1"; > > let $x := <value>4.6622388E7</value> > let $y := $x/text() > return > xs:long(number($y)) > > However, when I use the same conversion in my code, I get an error > complaining about xs:double('NaN') to xs:long > > Why is number($y) returning 'NaN'. What do I need to do to get convert > scientific notation to an integer? > > Nick > > > > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open -- Nick Sincaglia President/Founder NueMeta, LLC Digital Media & Technology Phone: +1-630-303-7035 nsi...@nu... http://www.nuemeta.com Skype: nsincaglia |