Larry, If I understand right, just change the direction of the second sort to put the beginners first, this worked for my test:
on mouseUp sort lines of fld "sortField" by word 2 of each sort lines of fld "sortField" descending by word 1 of each end mouseUp Paul On 2014-08-09, at 4:56 AM, la...@significantplanet.org wrote: > Hello Alex, > OK, in my previous email I gave some hypothetical data. > In my app I actually have a field where the first word is either Advanced or > Beginner > The 2nd word is a number ranging from 2 to 25, showing how many items. > There are some other words after those, but I'm not concerned about them. > > As lines are added to the field, they are in jumbled order. > What I want is this on the sort: (All the Beginners in numeric order, > followed by all the Advanced in numeric order) > Beginner 1 > Beginner 2 > Beginner 3 (etc.) > Advanced 1 > Advanced 2 > Advanced 3 (etc.) > > Thanks, > Larry > > > ----- Original Message ----- From: "Alex Tweedly" <a...@tweedly.net> > To: <use-livecode@lists.runrev.com> > Sent: Saturday, August 09, 2014 3:51 AM > Subject: Re: sorting > > > Larry, > can you be more explicit about how it doesn't work ? > > Actually, can you explain better what you want to do ? You said you want > to sort by the 2nd and then the 3rd word - but gave an example that > appeared to show sorting by 2nd and 1st - and not even have a 3rd word > in any line. > > So how about a slightly less terse description, and an example showing > both "before" and "after" and hopefully we can get you to where you want > .... > > -- Alex. > > > On 09/08/2014 09:14, la...@significantplanet.org wrote: >> Sorry, that doesn't work >> >> ----- Original Message ----- From: "Björnke von Gierke" <b...@mac.com> >> To: "How to use LiveCode" <use-livecode@lists.runrev.com> >> Sent: Saturday, August 09, 2014 12:58 AM >> Subject: Re: sorting >> >> >>> sort theList by word 2 of each >>> sort theList by word 1 of each >>> >>> sort order is retained in-between commands, that's why it works. >>> >>> On 09 Aug 2014, at 08:24, la...@significantplanet.org wrote: >>> >>>> I have a field I want to sort. >>>> Each line has 4 words. >>>> I want to sort by the first word (ascending) and then do a 2nd sort by the >>>> 3rd word without changing the order of the first word. >>>> >>>> Example: >>>> >>>> apple box >>>> apple pie >>>> apple zoo >>>> baby blue >>>> baby rattle >>>> baby zoo >>>> etc. >>>> >>>> TIA >>>> Larry >>>> _______________________________________________ >>>> use-livecode mailing list >>>> use-livecode@lists.runrev.com >>>> Please visit this url to subscribe, unsubscribe and manage your >>>> subscription preferences: >>>> http://lists.runrev.com/mailman/listinfo/use-livecode >>> >>> >>> _______________________________________________ >>> use-livecode mailing list >>> use-livecode@lists.runrev.com >>> Please visit this url to subscribe, unsubscribe and manage your >>> subscription preferences: >>> http://lists.runrev.com/mailman/listinfo/use-livecode >> >> >> _______________________________________________ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your subscription >> preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode > > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode