Subject: RE: [xsl] Correcting an XML documentxsl-list@lists.mulberrytech.c om From: David.Pawson@xxxxxxxxxxx Date: Fri, 16 Jul 2004 07:42:05 +0100 |
The identity transform is the answer here, I'm curious if anyone could suggest a question or topic or something such that I can have a page in the faq where use cases for the identity tranform is the answer. Change a fraction of an input document, copy the rest. Generate a stylesheet with templates for every unique element. .. Others? TIA, DaveP -----Original Message----- From: walter.crockett A software application I use produces XML documents with inaccurate information. I need to change a few values within the document and output the whole corrected document as XML. Two kinds of changes are necessary, both in nearly the same place in the document structure: 1. For each /AttributeProps/Datatype element with a value of DATE, I need to change DATE to TIMESTAMP. 2. For each /AttributeProps/Order element, I need to take whatever the value of Order is and then use that value to replace the value of /AttributeProps/PhysicalOrder. So if Order has the value 1, PhysicalOrder must have the value 1 also. (This may already be true in many cases, but I imagine there's no sense in testing that they're equivalent. I would be just as easy to overwrite the value of PhysicalOrder every time, wouldn't it?) So, basically, I need to change two types of things and then copy over the entire XML document with the changes in it. This would seem very simple, but I'm at a loss. Walter Crockett -- DISCLAIMER: NOTICE: The information contained in this email and any attachments is confidential and may be privileged. If you are not the intended recipient you should not use, disclose, distribute or copy any of the content of it or of any attachment; you are requested to notify the sender immediately of your receipt of the email and then to delete it and any attachments from your system. RNIB endeavours to ensure that emails and any attachments generated by its staff are free from viruses or other contaminants. However, it cannot accept any responsibility for any such which are transmitted. We therefore recommend you scan all attachments. Please note that the statements and views expressed in this email and any attachments are those of the author and do not necessarily represent those of RNIB. RNIB Registered Charity Number: 226227 Website: http://www.rnib.org.uk
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Merge? Copy?, Mukul Gandhi | Thread | RE: [xsl] Correcting an XML docume, walter . crockett |
RE: [xsl] XSL documentor, David . Pawson | Date | Re: [xsl] RE: xslt processing and s, Emmanouil Batsis |
Month |