Sponsored Content
Top Forums Shell Programming and Scripting File comparison based on contents Post 302769602 by Ethen561 on Tuesday 12th of February 2013 09:01:17 PM
Old 02-12-2013
Wrench

Sorry abt the notations.
I will work on this ..
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

sh script that reads/writes based upon contents of a file

Hi everyone, Ive got a quick question about the feasibility and any suggestions for a shell script. I can use sh or ksh, doesnt matter. Basically, Ive got an output file from a db2 command that looks like so: SCHEMA NAME CARD LEAF ELEAF LVLS ISIZE NDEL KEYS F4 F5 ... (3 Replies)
Discussion started by: rdudejr
3 Replies

2. Shell Programming and Scripting

Remove lines based on contents of another file

So, this issue is driving me nuts! I was hoping to get a lending hand here... I have 2 files: file1.txt contains: this is example1 this is example2 this is example3 this is example4 this is example5 file2.txt contains: example3 example5 Basically, I need a script or command to... (4 Replies)
Discussion started by: bashshadow1979
4 Replies

3. Shell Programming and Scripting

Removing rows from a file based on date comparison

I have a '|' delimited file and want to remove all the records from the file if the date is greater than a year from sysdate. The layout of the file is as below - xxxxxxxxxxxxxx|yyyyyy|zzzzzz|2009-12-27-00:00| 000000000|N xxxxxxxxxxxxxx|yyyyyy|zzzzzz|2010-01-03-00:00| 000000000|N... (4 Replies)
Discussion started by: Max_2503
4 Replies

4. Shell Programming and Scripting

Execution problem with sort the file based on contents

My input file: >ali ASSDDGHFHFHJFJHJDSDGSDGSDGSDGSDGSDGSDGDSGDSGSDGDSGSDGSDGDSGSDGGDSG >zzz ASdASDASDSADSADDSADJKHJDSADKLJADKLSAJDLJLKJLDASDDSADd >abu ASDASDFSAFASFSADFASDASDSADSADSADSADSADSADASDASdSADSADSADA >aaa... (2 Replies)
Discussion started by: patrick87
2 Replies

5. Shell Programming and Scripting

move contents from one file to another based on line number or content

I want a script that will move everything beyond a certain line number or beyond a certain content word into another file. For example, if file A has this: first line second line third line forth line fifth line sixth line I want to run a script that will move everything beyond the third... (4 Replies)
Discussion started by: robp2175
4 Replies

6. UNIX for Dummies Questions & Answers

count values based on contents of another file

Hello, I have two files as shown below: test1 678 679 689 690 710 test2 1 678 654 800 676 791 689 900 I want to get a count of lines from test2 whose columns bound the values in test1 I tried running the code below; however am getting wrong results. (3 Replies)
Discussion started by: Gussifinknottle
3 Replies

7. UNIX for Dummies Questions & Answers

find lines in another file based on contents in a second file

Hello, I have a file with tab delimited columns like: File1 A 2 C R F 4 D Q C 9 A B ...... I want to grep out the lines in a second file, File2, corresponding to each line in File1 Can I do this: while read a b c d do grep '$a\t$b\t$c\t$d' File2 >>... (2 Replies)
Discussion started by: Gussifinknottle
2 Replies

8. Shell Programming and Scripting

Merging two file based on comparison of first columns

Respected Members. Hello. This is my first post in the forum. I will try to follow all the rules as prescribed by the forum. In case of non-compliance, I request you to kindly give me some more time to understand and abide by them. I am working on two files. I wish to merge the two files... (1 Reply)
Discussion started by: manojmalhotra
1 Replies

9. Shell Programming and Scripting

Merging two file based on comparison of first columns

Respected Members. Hello. This is my first post in the forum. I will try to follow all the rules as prescribed by the forum. In case of non-compliance, I request you to kindly give me some more time to understand and abide by them. I am working on two files. I wish to merge the two files... (6 Replies)
Discussion started by: manojmalhotra
6 Replies

10. Shell Programming and Scripting

Remove or rename based on contents of file

I am trying to use the two files shown below to either remove or rename contents in one of those files. If in file1.txt $5 matches $5 of file2.txt and the value in $1 of file1.txt is not "No Match" then that value is substituted for all values in $5 and $1 of file2.txt. If however in $1 ... (5 Replies)
Discussion started by: cmccabe
5 Replies
XML::DOM::DocumentType(3)				User Contributed Perl Documentation				 XML::DOM::DocumentType(3)

NAME
XML::DOM::DocumentType - An XML document type (DTD) in XML::DOM DESCRIPTION
XML::DOM::DocumentType extends XML::DOM::Node. Each Document has a doctype attribute whose value is either null or a DocumentType object. The DocumentType interface in the DOM Level 1 Core provides an interface to the list of entities that are defined for the document, and little else because the effect of namespaces and the various XML scheme efforts on DTD representation are not clearly understood as of this writing. The DOM Level 1 doesn't support editing DocumentType nodes. Not In DOM Spec: This implementation has added a lot of extra functionality to the DOM Level 1 interface. To allow editing of the DocumentType nodes, see XML::DOM::ignoreReadOnly. METHODS getName Returns the name of the DTD, i.e. the name immediately following the DOCTYPE keyword. getEntities A NamedNodeMap containing the general entities, both external and internal, declared in the DTD. Duplicates are discarded. For example in: <!DOCTYPE ex SYSTEM "ex.dtd" [ <!ENTITY foo "foo"> <!ENTITY bar "bar"> <!ENTITY % baz "baz"> ]> <ex/> the interface provides access to foo and bar but not baz. Every node in this map also implements the Entity interface. The DOM Level 1 does not support editing entities, therefore entities cannot be altered in any way. Not In DOM Spec: See XML::DOM::ignoreReadOnly to edit the DocumentType etc. getNotations A NamedNodeMap containing the notations declared in the DTD. Duplicates are discarded. Every node in this map also implements the Notation interface. The DOM Level 1 does not support editing notations, therefore notations cannot be altered in any way. Not In DOM Spec: See XML::DOM::ignoreReadOnly to edit the DocumentType etc. Additional methods not in the DOM Spec Creating and setting the DocumentType A new DocumentType can be created with: $doctype = $doc->createDocumentType ($name, $sysId, $pubId, $internal); To set (or replace) the DocumentType for a particular document, use: $doc->setDocType ($doctype); getSysId and setSysId (sysId) Returns or sets the system id. getPubId and setPubId (pudId) Returns or sets the public id. setName (name) Sets the name of the DTD, i.e. the name immediately following the DOCTYPE keyword. Note that this should always be the same as the element tag name of the root element. getAttlistDecl (elemName) Returns the AttlistDecl for the Element with the specified name, or undef. getElementDecl (elemName) Returns the ElementDecl for the Element with the specified name, or undef. getEntity (entityName) Returns the Entity with the specified name, or undef. addAttlistDecl (elemName) Adds a new AttDecl node with the specified elemName if one doesn't exist yet. Returns the AttlistDecl (new or existing) node. addElementDecl (elemName, model) Adds a new ElementDecl node with the specified elemName and model if one doesn't exist yet. Returns the AttlistDecl (new or existing) node. The model is ignored if one already existed. addEntity (notationName, value, sysId, pubId, ndata, parameter) Adds a new Entity node. Don't use createEntity and appendChild, because it should be added to the internal NamedNodeMap containing the entities. Parameters: notationName the entity name. value the entity value. sysId the system id (if any.) pubId the public id (if any.) ndata the NDATA declaration (if any, for general unparsed entities.) parameter whether it is a parameter entity (%ent;) or not (&ent;). SysId, pubId and ndata may be undefined. DOMExceptions: o INVALID_CHARACTER_ERR Raised if the notationName does not conform to the XML spec. addNotation (name, base, sysId, pubId) Adds a new Notation object. Parameters: name the notation name. base the base to be used for resolving a relative URI. sysId the system id. pubId the public id. Base, sysId, and pubId may all be undefined. (These parameters are passed by the XML::Parser Notation handler.) DOMExceptions: o INVALID_CHARACTER_ERR Raised if the notationName does not conform to the XML spec. addAttDef (elemName, attrName, type, default, fixed) Adds a new attribute definition. It will add the AttDef node to the AttlistDecl if it exists. If an AttDef with the specified attrName already exists for the given elemName, this function only generates a warning. See XML::DOM::AttDef::new for the other parameters. getDefaultAttrValue (elem, attr) Returns the default attribute value as a string or undef, if none is available. Parameters: elem The element tagName. attr The attribute name. expandEntity (entity [, parameter]) Expands the specified entity or parameter entity (if parameter=1) and returns its value as a string, or undef if the entity does not exist. (The entity name should not contain the '%', '&' or ';' delimiters.) POD ERRORS
Hey! The above document had some coding errors, which are explained below: Around line 62: You forgot a '=back' before '=head2' Around line 64: '=item' outside of any '=over' perl v5.12.1 2002-02-09 XML::DOM::DocumentType(3)
All times are GMT -4. The time now is 09:10 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy