This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Adding together XML files with identical trees


> I'm sure Oliver Becker will point you in this direction
> http://www.informatik.hu-berlin.de/~obecker/XSLT/#merge
> but just in case you're in the states and he's asleep
> there you go

Now I'm wide awake again :-)

It seems there could be a little problem.
The input contains

> >		<LOGINFO>
> >			<PERFORMANCE>32ms</PERFORMANCE>
> >		</LOGINFO>

whereas the output should look like

> >		<LOGINFO>
> >			<PERFORMANCE1>32ms</PERFORMANCE1>
> >			<PERFORMANCE2>45ms</PERFORMANCE2>
> >			<PERFORMANCE3>45ms</PERFORMANCE3>
> >		</LOGINFO>

There appear new elements with suffixes 1, 2, ...
My merge tool would probably give
> >		<LOGINFO>
> >			<PERFORMANCE>32ms45ms45ms</PERFORMANCE>
> >		</LOGINFO>
(Haven't tried it).

So it's not the perfectly fitting solution, but it could be a suggestion
to Mike.

Another note: the merge stylesheet merges arbitrary XML documents.
If one knows the XML structure then it could be done much simpler.

Cheers,
Oliver


/-------------------------------------------------------------------\
|  ob|do        Dipl.Inf. Oliver Becker                             |
|  --+--        E-Mail: obecker@informatik.hu-berlin.de             |
|  op|qo        WWW:    http://www.informatik.hu-berlin.de/~obecker |
\-------------------------------------------------------------------/


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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]