Colleen, Thanks for your prompt answer. I did as you said and, sure enough, the report says:
... order by xs:string(($result//_1:author)[1]) ... Tim Finney On Fri, 2011-12-02 at 14:11 -0800, Colleen Whitney wrote: > Tim, I believe that the first author in the sequence is used by > default, anyway. To test that, run a search with the > <debug>true</debug> flag in your options node, and the output will > contain a report that shows you exactly what the flwor expression > was. > > Of course if you wanted the second one, you'd be out of luck, but for > this case I think you'll get that behavior anyway. > > --Colleen > ________________________________________ > From: [email protected] > [[email protected]] On Behalf Of Tim Finney > [[email protected]] > Sent: Friday, December 02, 2011 1:59 PM > To: [email protected] > Subject: [MarkLogic Dev General] search:search sort operator > > Hi All, > > I have a lot of docs, each with one or more author elements. Is there > an > easy way to tell search:search() to only look at the first author > element when returning search results ordered by author? _______________________________________________ General mailing list [email protected] http://developer.marklogic.com/mailman/listinfo/general
