Delete XML Node or Attribute

Deletes all the nodes/attributes that match the Xpath expression in a given XML file. Used to remove a specified node. When a node is removed, all its child nodes are also removed.

AWE's XML actions require a basic understanding of XML and related terms, such as XPath, DTD and XSLT.

Declaration

<AMXMLDELETENODE XPATH="text" />

Example

Delete nodes at XPath "/bookstore/book/price/Euro". Session name is "XMLSession1"

<AMXMLDELETENODE XPATH="/bookstore/book/price/Euro" />

See Also: Create XML Node, Delete XML Node, Edit XML Node, End XML Session, Evaluate Xpath Expression, Extract XML Fragment, Merge XML Files, Output XML, Read XML Node, Sign XML Document, Start XML Session, Transform XML, Validate XML File, Verify XML Document, XML Node to Dataset

General Tab

Property

Type

Required

Default

Markup

Description

XPath Expression

Text

Yes

(Empty)

XPATH="/BookStore/Books/Price"

The Xpath expression to the XML node in which to delete.

Attribute (optional)

Text

No

(Empty)

ATTRNAME="attributeName"

The attribute in which to delete.

Session Name

Text

Yes

(Empty)

SESSIONNAME="FirstXMLSession"

The session name to identify the in-memory XML document to use in subsequent XML steps. This allows several in memory XML documents to be active simultaneously.