这是非常简单的示例 xml 文件:
<?xml version="1.0" encoding="UTF-8"?>
<bookstore><book category="children">
<title lang="en">Harry Potter</title>
<author>J K. Rowling</author>
<year>2005</year>
<price>29.99</price>
<text>There are several harry potter books: -Chamber of Secrets -Goblet of Fire -</text>
</book>
</bookstore>
使用 NiFi,我想
- 将文本字段重命名为
books
- 然后创建一个子字段
book-items
,其中密室作为一个元素,火焰杯作为另一个元素
我正在使用 EvaluateXpath 处理器来提取值。我不确定如何将文本字段提取为单独的对象