tjones said the following on 09/22/2010 11:48 AM:
<cfset appVers = "3.6.1,3.6.5,3.6.3,3.6.10">
<cfset appVers2 = ListSort(appVers,"Numeric","DESC",",")>
On ACF8, I get:

3.6.10,3.6.5,3.6.3,3.6.1

Trying this on OpenBD:

<cfset appVers = "3.6.1,3.6.5,3.6.3,3.6.10">
<cfset appVers2 = ListSort(appVers,"Text","DESC",",")>

I get:

3.6.5,3.6.3,3.6.10,3.6.1

The sort order if going to be different as numerically -- 3.6.1 and 3.6.10 are equal. The results from CF not sorted right in my book.

Technically, 3.6.1 is not a number -- it's a string in the true sense (because numbers only have one decimal). I'm surprised it works in CF at all.

.pjf

--
Open BlueDragon Public Mailing List
http://www.openbluedragon.org/   http://twitter.com/OpenBlueDragon
official manual: http://www.openbluedragon.org/manual/
Ready2Run CFML http://www.openbluedragon.org/openbdjam/

mailing list - http://groups.google.com/group/openbd?hl=en

Reply via email to