Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!rutgers!rochester!pt.cs.cmu.edu!cat.cmu.edu!ns From: ns@cat.cmu.edu (Nicholas Spies) Newsgroups: comp.sys.mac.hypercard Subject: Re: Sorting by multiple keys Message-ID: <4388@pt.cs.cmu.edu> Date: 1 Mar 89 17:44:28 GMT References: <2053@tank.uchicago.edu> Distribution: usa Organization: Carnegie-Mellon University, CS/RI Lines: 20 In article <2053@tank.uchicago.edu> ben@rover.bsd.uchicago.edu writes: >I want to sort my cards by two "keys"... You can sort by concatenating the contents of fields (e.g. sort by field "a" & field "b") In fact, you can sort by the result of an expression or function, so long as the expression or function can be applied to each card. Thus sort by field "xx" is empty & field "xx" -- will sort by field "xx", but put empty field "xx" cards at the end (rather than the beginning) of the stack. Why? Because -- field "xx" is empty -- evaluates to either TRUE or FALSE. The same technique can be used using functions. -- Nicholas Spies ns@cat.cmu.edu.arpa Center for Design of Educational Computing Carnegie Mellon University --