Thank you _ that solved it. Amélie Please consider the environment before printing this e-mail or any of its attachments (if applicable)
-----Original Message----- From: python-list-bounces+aydavis=purdue....@python.org [mailto:python-list-bounces+aydavis=purdue....@python.org] On Behalf Of Raymond Hettinger Sent: Wednesday, April 29, 2009 10:31 AM To: python-list@python.org Subject: Re: sorting items in a table problematic because of scientific notation [John Machin] > > 'NEAR_DIST'], [('N', 9, 0), ('N', 9, 0), ('F', 19, 11)], [53, 55, ' > > The data type code for the offending column is "F" which is not in the > bog-standard dBase III set of C, N, D, and L. The code that you have used > merely > returns unchanged the character string that finds in the data base. > > > > > 1.05646365517e+005'], [53, 6, ' 9.32599134016e+004'], [53, 0, ' > > 8.97477154418e+004'], [53, 2, ' 8.96449127749e+004'], [53, 1, ' > > 7.88170078501e+004'], [53, 5, ' 8.29281503631e+004'], [53, 4, ' FWIW, I just updated the recipe to handle an F typecode by casting it to a float. Hope this helps. Raymond -- http://mail.python.org/mailman/listinfo/python-list -- http://mail.python.org/mailman/listinfo/python-list