gpt4 book ai didi

java - 在hadoop上解析xml文件...

转载 作者:行者123 更新时间:2023-12-01 13:58:44 30 4
gpt4 key购买 nike

如何在 Hadoop 上解析具有如下结构的 xml 文件:

<row Id="2292" PostTypeId="2" ParentId="2284" CreationDate="2008-08-05T13:28:06.700" Score="0" ViewCount="0" Body="&lt;p&gt;The first thing you should do is contact the main people who run the open source project. Ask them if it is ok to contribute to the code and go from there.&lt;/p&gt;&#xD;&#xA;&#xD;&#xA;&lt;p&gt;Simply writing your improved code and then giving it to them may result in your code being rejected.&lt;/p&gt;" OwnerUserId="383" LastActivityDate="2008-08-05T13:28:06.700" />

注意:我已经为其编写了代码,但它无法正常工作。需要一种新的方法...

提前致谢...

最佳答案

看看XMLInputFormat ,可能需要稍微修改一下。

关于java - 在hadoop上解析xml文件...,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19476659/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com