Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries >Thread Prev - Grouping based on several values [Thread Next] Re: Grouping based on several valuesTo: NULL Date: 9/5/2006 6:39:00 AM See an XSLT implementation of grouping with any number (dynamically defined) of levels: http://www.npcwm.xslt.com/html/xsl-list/2004-12/msg01030.html Cheers, Dimitre Novatchev "Colin Bowern" <colin.bowern@n...> wrote in message news:utI4zM7zGHA.4648@T...... >I have a document where I want to group based on values several levels >deep: > > <SalesOrder ...> > <LineItems> > <LineItem Id="1" DeliveryAddressId="Shipping" DeliveryMethodId="1" > SupplierId="A" /> > <LineItem Id="2" DeliveryAddressId="Shipping" DeliveryMethodId="2" > SupplierId="A" /> > <LineItem Id="3" DeliveryAddressId="Shipping" DeliveryMethodId="1" > SupplierId="B" /> > <LineItem Id="4" DeliveryAddressId="Billing" DeliveryMethodId="2" > SupplierId="B" /> > </LineItems> > </SalesOrder> > > The above example should ideally end up in four purchase orders because of > the combination of delivery address, method, and supplier. For example: > > <PurchaseOrder SupplierId="A" DeliveryMethod="1"> > <DeliveryAddress Id="Shipping" .. /> > <LineItems> > <LineItem Id="1" /> > </PurchaseOrder> > > At this point I've gotten to a point where I can build out single > line-item purchase orders based on this information. Ideally I want to > aggregate based on the three values using XSLT. > > Has anyone seen this scenario before? Are there any good resources that > you could share to help me understand what functions/approaches to take to > resolve this? > > Thanks, > Colin > | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
