|
|
Splitzer,
There's a flaw in the way you're building your list - I'm not sure why you're
doing it this way but you're appending one value list to another from the same
query so there's no way your values will stay sorted once you do this.
ie.
You're taking the (sorted) value list of wall.myID:
2
2
9
2
and then adding the (sorted) value list of wall.profileID to the end:
7
3
2
1
The reason why its not sorted correctly is right there - 9 is appearing first
because its in the first half of your list (see above).
If you want the results to stay sorted you'll need to try a different method
for combining the two lists of values, perhaps by looping through the query
results and building the list row by row.
<cfset final_id = "">
<cfloop query="wall">
<cfif wall.myID neq URL.id>
<cfset final_id = ListAppend(final_id,wall.myID)>
</cfif>
<cfif wall.profileID neq URL.id>
<cfset final_id = ListAppend(final_id,wall.profileID)>
</cfif>
</cfloop>
|
|