, "2", "");
> structInsert(s, "1", "");
>
> #structKeyList(s)#
>
>
>
>> -Original Message-
>> From: Dave Carabetta [mailto:[EMAIL PROTECTED]]
>> Sent: Wednesday, January 29, 2003 2:05 PM
>
TECTED]]
> Sent: Wednesday, January 29, 2003 2:05 PM
> To: CF-Talk
> Subject: RE: Struct Sort
>
>
> >Where does it say that struct keys are returned in insertion order? The
> >docs for structKeyList() and structKeyArray() say they are unordered.
>
> In the LiveDocs
>Where does it say that struct keys are returned in insertion order? The
>docs for structKeyList() and structKeyArray() say they are unordered.
In the LiveDocs on MM's site under Migrate ColdFusion 5 Applications, if you
scroll to the very bottom, you'll see that StructKeyList() now returns the
To: CF-Talk
> Subject: RE: Struct Sort
>
>
> >The reason there is no rhyme or reason is because structs are
> implemented
> >as
> >HashMaps in CFMX, which by definition don't have an order to the
> values. I
> >would imagine that you'll get them back i
>The reason there is no rhyme or reason is because structs are implemented
>as
>HashMaps in CFMX, which by definition don't have an order to the values. I
>would imagine that you'll get them back in hashCode() order, but that's not
>guarenteed consistent because of collision resolution.
Accordin
Probably was still a HashMap, but with a different
implementation of the getKeyList() method that sorted the key list first.
Nothing you can't solve with listSort() though.
> -Original Message-
> From: Sean Daniels [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, January 29,
>
> I'm guessing you are running MX in production, but not in dev. The
> ordering of structs changed from 5.0 to MX. There seems to be
> no rhyme
> or reason to the output order in MX. Fun.
The order of the keys returned by a struct was never promised - it just
happened to return in alpha orde
On Wednesday, January 29, 2003, at 03:13 PM, Brad Roberts wrote:
> I've got a structure that holds several questions:
>
> temp = structNew();
> temp.A = "a quesiton";
> temp.B = "another question";
> temp.C = "yet another question";
> ... and so on
>
> I'm outputing the questions like s
s the Force, and a powerful ally it is." - Yoda
> -Original Message-
> From: Brad Roberts [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, January 29, 2003 2:13 PM
> To: CF-Talk
> Subject: Struct Sort
>
>
> I've got a structure that holds several questions
I've got a structure that holds several questions:
temp = structNew();
temp.A = "a quesiton";
temp.B = "another question";
temp.C = "yet another question";
... and so on
I'm outputing the questions like so:
#temp[q]#:
For some reason, the questions won't stay in order on th
10 matches
Mail list logo