|
[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
[Recent Entries]
[Reply To This Message]
Re: Isolate spezial text term with pattern
Subject: Re: Isolate spezial text term with pattern
From: "Tammo Wenterodt" <Tammo.Wenterodt@xxxxxx>
Date: Mon, 25 Jul 2005 21:02:32 +0200
|
sed is short for stream editor, google will find 37100 entries for
http://www.google.de/search?hl=de&q=sed+%22stream+editor%22&btnG=Google-Suche&meta=
one page I found nice is
http://www.grymoire.com/Unix/Sed.html
Regards,
Tammo
Hello,
can you provide more information about "sed" ?
Thank you.
Greets Oliver
I think for this kind of conversion "sed" is better suited than xslt. With
the following commands you can change your whole document once and for all:
sed -e "s|</comment>|</pb>|g" document.xml > temp.xml
sed -e "s|PB|</comment><pb>|g" temp.xml > document.new.xml
The output will be:
<document>
<report>
<comment>Hallo commentar. </comment><pb>123</pb>
</report>
<report>
<comment>Hallo commentar. </comment><pb>456</pb>
</report>
</document>
Regards,
Tammo Wenterodt
Hello,
i have the following XML document (not complete):
<document>
<report>
<comment>Hallo commentar. PB123</comment>
</report>
<report>
<comment>Hallo commentar. PB456</comment>
</report>
......
</document>
What i now what to do is the following: I will islote the terms "PB123"
and
"PB456" and so on in the hole document. Therefore i need a spezial pattern
i
think. The pattern is always the same: "PB" and then 3 or 4 numbers. I
will
write this terms in an extra column in a HTML table.
How i get the text from <comment>...</comment> is clear for me. Thats no
problem.
I hope you know what i need. :)
Thank you for your support.
Greets Oliver

|
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format
| RSS 2.0 |
|
| Atom 0.3 |
|
|