If you get sorting like that it means that you have strings but not numbers. Either start using numbers for the values or if that is not possible convert the string to an integer in the emit function.
emit(parseInt(doc.my_number), doc); -- Jón Grétar Borgþórsson On Wed, Mar 17, 2010 at 11:05 AM, Luis Gomez <[email protected]> wrote: > Hi, quick one this time... > > How can I make a map function sort these keys numerically? Is there an > easy/conventional way or do I need to pad the numbers? > > > Thanks, > > Luis >
