couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Keen ...@visiture.com>
Subject Re: Strange integer anomaly in Erlang view
Date Tue, 11 May 2010 14:55:45 GMT
I'd say there's a good reason to store it as a number, if I want to be able to sort on that
field. But, even if you could make the case that this particular value should be stored as
a string, shouldn't we be able to expect data stored as an integer to be able to be retrieved
accurately?

Mike

On May 11, 2010, at 10:41 AM, Jarrod Roberson wrote:

> On Tue, May 11, 2010 at 10:37 AM, Jarrod Roberson <jarrod@vertigrated.com>wrote:
> 
>> this is a know issue with I reported here
>> https://issues.apache.org/jira/browse/COUCHDB-749
>> it has something to do with JavaScript precision with Numbers.
>> 
>> my solution was to just persist everything as strings and then convert back
> to the appropriate number type in my non-JavaScript client code. There is
> really no reason to store numerical ids as numbers anyway, it isn't like you
> are doing math on them on the server side.


Mime
View raw message