xsl-list
[Top] [All Lists]

Re: [xsl] Intersection of two sets based on a subset of fields?

2020-05-23 06:09:37
On Sat, 23 May 2020 at 05:24, Mukul Gandhi 
gandhi(_dot_)mukul(_at_)gmail(_dot_)com <
xsl-list-service(_at_)lists(_dot_)mulberrytech(_dot_)com> wrote:

On Thu, May 21, 2020 at 7:53 PM David Carlisle 
d(_dot_)p(_dot_)carlisle(_at_)gmail(_dot_)com <
xsl-list-service(_at_)lists(_dot_)mulberrytech(_dot_)com> wrote:

if $set1 is a your sequence of books and $set2 is your sequence of Music
then you seem to want

$set1[concat(Author,'#',Country)=$m/concat(Author,'#',Country) ]

assuming # doesn't appear in Author or Country names.


Nice solution.


short and easy to read but probably not that efficient for long lists
(unless saxon kindly rewrites this automatically to use a hashed key
lookup:-)



There seems to be a little type above. $m should be $set2?


er yes, sorry.




--
Regards,
Mukul Gandhi
XSL-List info and archive <http://www.mulberrytech.com/xsl/xsl-list>
EasyUnsubscribe <http://lists.mulberrytech.com/unsub/xsl-list/2739265> (by
email <>)

--~----------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
EasyUnsubscribe: http://lists.mulberrytech.com/unsub/xsl-list/1167547
or by email: xsl-list-unsub(_at_)lists(_dot_)mulberrytech(_dot_)com
--~--
<Prev in Thread] Current Thread [Next in Thread>