【发布时间】:2018-02-19 22:59:22
【问题描述】:
我需要获取多个值的路径,但是我正在使用的 Xquery 环境不支持这种语法
for $ancestor in $datum/ancestor-or-self::* 特别是这个轴导致问题ancestor-or-self::*。似乎无法弄清楚这一点。任何帮助表示赞赏
【问题讨论】:
我需要获取多个值的路径,但是我正在使用的 Xquery 环境不支持这种语法
for $ancestor in $datum/ancestor-or-self::* 特别是这个轴导致问题ancestor-or-self::*。似乎无法弄清楚这一点。任何帮助表示赞赏
【问题讨论】:
在没有ancestor* 轴的情况下,您可以递归地爬上parent 轴,或者使用root() 函数检索文档节点,然后沿着child 或descendant 轴下降。
【讨论】: