xsl-list
[Top] [All Lists]

RE: Grouping the same set by multiple criteria

2003-05-28 09:07:30
<Ken said>
At 2003-05-28 09:49 -0500, Erika Marlow wrote:
I have used the Muenchian
technique to find the unique groups, but I am stuck on how to get the
counts
for the different groupings.

Go back to the key table and count the number of members of the table for 
which the Muenchian method was used to collect common values.

For example, if you used

   //transaction[ generate-id(.)=
                  generate-id(key('bydates',original_request/inquiry/@date))
]

then you can get the count of those by that date using:

   count( key( 'bydates', original_request/inquiry/@date ) )

I hope this helps.

............... Ken
</Ken said>

I don't think I quite understand.  The first line produces the set of
transaction nodes that have unique dates; for the example data provided
previously: <transaction> - 20030128 and <transaction> - 20030528.  The
second line then gives a result of 2, the number of nodes in the key set not
the number of transaction nodes that match 20030128 and the number of nodes
that match 20030528 and so on.

Maybe a different way to phrase my question is, how do I count the number of
transactions that match the criteria date==20030128, site==0000 and
payer==00003?

I am able to find the unique dates, sites and payers to sort by, but I am
unable to count each set.

Thanks,
Erika

end 



------------  Gateway EDI, Inc.  
---------------------------------------------------------------------------------------------------

This email and any files transmitted with it are confidential and intended 
solely for the use of the individual or entity to whom they are addressed.  If 
you are not the intended addressee, or the person responsible for delivering it 
to them, you may not copy, forward, disclose or otherwise use it or any part of 
it in any way.  To do so may be unlawful.  If you receive this email by 
mistake, please advise the sender immediately and destroy all copies of the 
original message.


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>