You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by Kakoli <ka...@india.hp.com> on 2000/06/12 09:56:49 UTC
Urgent query!
Hello everybody,
I wanted some code which will operate on two xml files to form a
resultant xml file in the fol. way,
a.xml + b.xml = c.xml, where
a.xml : <a>...</a>
b.xml : <b>...</b>
c.xml : <a>...</a>
<b>...</b>.
Regards,
Kakoli
RE: Urgent query!
Posted by "iunknown@pn3" <iu...@pn3.vsnl.net.in>.
Hi:
Try using XSLT for the same.
If you could send the complete two XMl files,
I can show you how to do the same.
regards
IUnknown
-----Original Message-----
From: Kakoli [mailto:kakoli@india.hp.com]
Sent: Monday, June 12, 2000 1:27 PM
To: xerces-cvs@xml.apache.org
Subject: Urgent query!
Hello everybody,
I wanted some code which will operate on two xml files to form a
resultant xml file in the fol. way,
a.xml + b.xml = c.xml, where
a.xml : <a>...</a>
b.xml : <b>...</b>
c.xml : <a>...</a>
<b>...</b>.
Regards,
Kakoli
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-cvs-help@xml.apache.org
Re: Urgent query!
Posted by Daniel Barclay <Da...@digitalfocus.com>.
> From: Kakoli [mailto:kakoli@india.hp.com]
> Sent: Monday, June 12, 2000 12:57 AM
> To: xerces-cvs@xml.apache.org
> Subject: Urgent query!
>
> Hello everybody,
> I wanted some code which will operate on two xml files to form a
> resultant xml file in the fol. way,
> a.xml + b.xml = c.xml, where
> a.xml : <a>...</a>
> b.xml : <b>...</b>
> c.xml : <a>...</a>
> <b>...</b>.
Your c.xml is not XML.
--
Daniel Barclay
Digital Focus
Daniel.Barclay@digitalfocus.com
RE: Urgent query!
Posted by Christopher Taylor <cs...@pacbell.net>.
Haven't tried it myself... but from the docs this is what you'd do (if using
DOM):
read a.xml into DocumentA
read b.xml into DocumentB
create DocumentC using a DOMImplementation (you can ask one of the previous
objects for it's DOMImplementation)
TopNodeA = Import root node from DocumentA into C using
DocumentC.importNode(DocumentA.getDocumentElement(),true);
TopNodeB = Import root node from DocumentB into C using
DocumentC.importNode(DocumentB.getDocumentElement(),true);
Set the document node for DocumentC to be TopNodeA
Append TopNodeB to TopNodeA
That should do it... like I said, I haven't tried it myself, but it should
work.
-Chris
-----Original Message-----
From: Kakoli [mailto:kakoli@india.hp.com]
Sent: Monday, June 12, 2000 12:57 AM
To: xerces-cvs@xml.apache.org
Subject: Urgent query!
Hello everybody,
I wanted some code which will operate on two xml files to form a
resultant xml file in the fol. way,
a.xml + b.xml = c.xml, where
a.xml : <a>...</a>
b.xml : <b>...</b>
c.xml : <a>...</a>
<b>...</b>.
Regards,
Kakoli
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-cvs-help@xml.apache.org