03-12-2009
sed or awk to extract data from Xml file
Hi, I want to get data from Xml file by using sed or awk command. I want to get the following result :
mon titre 1;Createur1;Dossier1
mon titre 1;Createur1;Dossier1
and save it in cvs file (fichier.cvs).
FROM this Xml file (test.xml):
<playlist version="1">
<trackList>
<track>
<title>Mon titre 1</title>
<creator>Createur1</creator>
<location>Dossier1</location>
</track>
<track>
<title>Mon titre 2</title>
<creator>Createur2</creator>
<location>Dossier2</location>
</track>
</trackList>
</playlist>
thanks for your help !
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
This is the xml file that i have.
- <front-servlet platform="WAS4.0" request-retriever="SiteMinder-aware" configuration-rescan-interval="60000">
<concurrency-throttle maximum-concurrency="50" redirect-page="/jsp/defaulterror.jsp" />
- <loggers>
<instrumentation... (5 Replies)
Discussion started by: nishana
5 Replies
2. Shell Programming and Scripting
Hi,
I need to extract the start time value (bold, red font) under the '<LogEvent ID="Timer Start">' tag (black bold) from a file with the following pattern. There are other LogEventIDs listed in the file as well, making it harder for me to extract out the specific start time that I need.
.
.... (7 Replies)
Discussion started by: 60doses
7 Replies
3. Shell Programming and Scripting
Hello Scripting Gurus,
I need help with extracting data from the XML file using shell script.
The data is in a large XML and I need to extract the id values of all completedworkflows. Here is a sample of it. Input and output data is also in the attached text files.
<wfregistry>... (5 Replies)
Discussion started by: yajaykumar
5 Replies
4. Shell Programming and Scripting
Please help me out to extract the Data from the XML Log files.
So here is the data
ERROR|2010-08-26 00:05:52,958|SERIAL_ID=128279996|ST=2010-08-2600:05:52|DEVICE=113.2.21.12:601|TYPE=TransactionLog... (9 Replies)
Discussion started by: raghunsi
9 Replies
5. Shell Programming and Scripting
Hello everyone,
Firstly i do not require alot of help.. i am right at the end of finishing my scipt but cannot find a solution to the last part.
What i need to do is, prompt the user for a file to work with, which i have done.
promt the user for an output file - which is done.
#!/bin/bash... (14 Replies)
Discussion started by: hugh86
14 Replies
6. Shell Programming and Scripting
hi,
please help, i have an xml file, e.g:
...
<tag> test text
asdas="${abc}"
xvxvbs:asdas${222}sdad
asasa="${aa_bb_22}"
</tag>
...
i want to extract all "${...}", e.g:
${abc}
${222}
${aa_bb_22}
thank you. (2 Replies)
Discussion started by: gioni
2 Replies
7. Shell Programming and Scripting
Hi ,
I have input file as XML. following are input data
#complex.xml
<?xml version="1.0" encoding="UTF-8"?>
<TEST_doc xmlns="http://www.w3.org/2001/XMLSchema-instance">
<ENTRY uid="123456">
<protein>
<name>PROT001</name>
<organism>Human</organism>
... (1 Reply)
Discussion started by: mohan sharma
1 Replies
8. Shell Programming and Scripting
Hi evry1,
This is my 1st post in this forum.Pls help me
I want to extract some data froma xml file which has 2000 lines using shell scripting. Actually my xml file has some "audio and video codes" which i need to arrange in a column wise format after extracting it using shell scripting.I... (4 Replies)
Discussion started by: arun_kohan
4 Replies
9. Shell Programming and Scripting
Hi ,
I have input file as XML. following are input data
#complex.xml
Code:
<?xml version="1.0" encoding="UTF-8"?><TEST_doc xmlns="http://www.w3.org/2001/XMLSchema-instance"> <ENTRY uid="123456"> <protein> <name>PROT001</name> <organism>Human</organism> ... (1 Reply)
Discussion started by: arun_kohan
1 Replies
10. Shell Programming and Scripting
Hi Guys,
I am in a need to extract data from a xml file. The XML file format is as below.
<data jsxnamespace="propsbundle" locales="">
<locale>
<!--Error messages starts-->
<record jsxid="CHARPAIR001" jsxtext=" must be selected"></record>
<record... (1 Reply)
Discussion started by: Showdown
1 Replies
LEARN ABOUT DEBIAN
mono-xmltool
mono-xmltool(Mono 1.0) mono-xmltool(Mono 1.0)
NAME
mono-xmltool - Mono XML validation and transformation tool.
SYNOPSIS
mono-xmltool --validate [*.rng | *.rnc | *.nvdl | *.xsd] [instances]
mono-xmltool --validate-rng relax-ng-grammar-xml [instances]
mono-xmltool --validate-rnc relax-ng-compact-grammar-file [instances]
mono-xmltool --validate-nvdl nvdl-script-xml [instances]
mono-xmltool --validate-xsd xml-schema [instances]
mono-xmltool --transform stylesheet instance-xml
mono-xmltool --prettyprint [source [result]]
DESCRIPTION
mono-xmltool is a command line front end for various functions available in the Mono XML class libraries. It currently it offers validation
with various different kinds of schemas, xslt transformations and pretty printing.
XML VALIDATION
mono-xmltool can validate a given set of XML files (the instances parameter) using the given schema file. Currently supported schema files
include Relax NG (*.rng), Compact Relax NG (*.rnc), Namespace-based Validation Dispatching Language (*.nvdl) and XML Schema (*.xsd).
If invoked with the --validate argument, Mono will use the filename extension to guess the kind of validation required. The --validate-xxx
flags would force a specific kind of validation.
The following lists the flags and the actual class that implements them in Mono:
--validate-rng
Commons.Xml.Relaxng.RelaxNgPattern as the schema, and Commons.Xml.Relaxng.RelaxngValidatingReader validator.
--validate-rnc
Commons.Xml.Relaxng.RncParser as the schema, and Commons.Xml.Relaxng.RelaxngValidatingReader validator.
--validate-nvdl
Commons.Xml.Nvdl as the schema and Commons.Xml.NvdlValidatingReader validator.
--validate-xsd
System.Xml.Schema.XmlSchema as the schema and uses System.Xml.XmlValidatingReader as the validator.
TRANSFORMATIONS
This does an XSLT transformation. The stylesheet must be an XSLT file, the instance-xml is the document to be processed. Output it sent to
the standard output.
PRETTY PRINTING
Produces a pretty-print rendering of the source file. If it is not specified it reads the standard input. If result is not specified,
the output is sent to the standard output.
MAILING LISTS
Mailing lists are listed at the http://www.mono-project.com/Mailing_Lists
WEB SITE
http://www.mono-project.com
SEE ALSO
mono(1),mcs(1).
mono-xmltool(Mono 1.0)