08-12-2013
How to extract data from xml file using shell 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 cant put the data manually as it will take much time ..
pls help Experts ...
Thanks in advance
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
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>... (1 Reply)
Discussion started by: yeclota
1 Replies
5. Shell Programming and Scripting
Hi,
i want to fetch the data from the alert log file, for a particular time interval.
Example :
Alert log content :
Thu Mar 18 08:47:36 2010
Completed: alter database open
Thu Mar 18 19:13:38 2010
MMNL absent for 6390 secs; Foregrounds taking over
Fri Mar 19 08:30:52 2010... (1 Reply)
Discussion started by: Pinki018
1 Replies
6. 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
7. Shell Programming and Scripting
Hi,
I am new to shell scripting. I need to extract data between repeating tags from an xml file and store the data in an array to process it further.
<ns1:root xmlns:ns1="http://example.com/config">
<ns1:interface>in1</ns1:interface>
<ns1:operation attribute1="true" attribute2="abd"... (2 Replies)
Discussion started by: sailendra
2 Replies
8. 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
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 SUSE
ivmconfigproperties.xml
IVMCONFIGPROPERTIES.XML(5) File Formats Manual IVMCONFIGPROPERTIES.XML(5)
NAME
IvmConfigProperties.xml - device properties to be monitored by ivman(8)
DESCRIPTION
IvmConfigProperties.xml specifies hardware properties to be monitored by ivman(8), and allows running of certain commands when device prop-
erties change.
IvmConfigProperties.xml is parsed as an XML file. The general form of the file is:
<?xml version="1.0" encoding="UTF-8"?>
<ivm:PropertiesConfig version="0.1" xmlns:ivm="http://www.eikke.com/ivm">
<ivm:Match name="matchname" value="matchvalue">
<ivm:Property name="propertyname">
<ivm:Action value="propertyvalue1" exec="command1" />
<ivm:Action value="propertyvalue2" exec="command2" />
...
</ivm:Property>
</ivm:Match>
...
</ivm:PropertiesConfig>
Each time a property changes on a device, this file will be parsed. If the Match rule matches the device on which the property changed,
and the Property rule matches the name of the property which changed, then all of the Action rules within that Property tag wil be parsed.
If 'value' is equal to the new value of the changed property, then the command specified in 'exec' will be executed.
A Match element can have any of the following names:
ivm.mountable
Whether or not HAL specifies that a device can and should be mounted. Must be "true" or "false".
hal.anything
The string in place of "anything" will be taken as the name of a HAL property string for the device, and the value of the prop-
erty will be compared to the value given. Run 'lshal' to see a list of HAL properties which can be used here.
* Match every device. Use with care!
As many Matches can be nested as is desired.
A Property element can have the following name:
hal.anything
The string in place of "anything" will be taken as the name of a HAL property string for the device, and if this is the prop-
erty that has changed, enclosed rules will be processed.
An Action element can have any string as its 'value'. If the new value of the changed property is equal to this string, then the command
given as the 'exec' property will be executed. It can also have the special value '*'; in this case, the 'exec' command will be executed
every time the property changes.
exec supports substitution of HAL device properties. This is accomplished by surrounding the property name with $ symbols. For instance,
if $hal.volume.mount_point$ is within a command, it will be replaced with the volume's mount point before execution. No character escaping
is done in the substitution, but the characters ' and " are replaced with ?, so you can surround the substitution with quotes without fear.
There is also a single Option which can be set in this file, and should be set outside of any Match or Property blocks. The syntax of this
option is:
<ivm:Option name="checkOnInit" value="true" />
If the value of checkOnInit is true, then Ivman will check every device on the system for matching rules when started. For example, if a
rule was present which started a service only when a particular volume was mounted, and Ivman was started when the volume was already
mounted, it would start the service if and only if checkOnInit was set to true.
Remember that this is an XML file, which means that characters which have a special meaning in XML (entities) need to be escaped. Some
characters which are popular in shell scripting (&, <, >) are among these special characters. As a quick reference, & becomes & , <
becomes < , > becomes > , ' becomes ' and " becomes " .
SEE ALSO
ivman(8), IvmConfigBase.xml(5), IvmConfigActions.xml(5), IvmConfigConditions.xml(5)
12 May 2005 IVMCONFIGPROPERTIES.XML(5)