我有一个用 Netbeans 构建的 Apache Derby 数据库。我想知道是否有将表格内容导出为 xml 的方法。
例如:
`<employee>
<name="Kal"/>
<ID=10/>
<employee/>` where employee is table name, name and ID just attributes
最佳答案
你有几个(免费)选项
- 将数据“打印”到 xml 格式的文件中(坏主意)
- 使用JAXB
- 使用XMLStreamWriter
所有这些都涉及编写一些 Java 代码。遗憾的是,Derby 中没有用于 XML 导出的内置功能。它只支持 CSV format .祝你好运!
关于database - Netbeans-Apache Derby : How to export to XML?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8347710/