1
我需要一個兔崽子SQL 2等效查詢此XPath查詢2等效查詢需要兔崽子SQL的XPath查詢
xpath = "/jcr:root//institutes/institute[*]/(@title | @overallScore)"
我有這樣的地方SQL2 我可以用ISCHILDNODE得到'/IN/institues/institute'
()約束
但我想以這種方式返回所有研究所'/%/institutes/institute'
。如果我能實現這個使用連接,請讓我知道了聲明全文
Currenlty我使用此查詢,但沒有成功
sql2 = "SELECT institute.title, institute.overallScore FROM [nt:unstructured] AS country "
+ "INNER JOIN [nt:unstructured] AS institutes ON ISCHILDNODE(institutes, country) "
+ "INNER JOIN [nt:unstructured] AS institute ON ISCHILDNODE(institute, institutes) "
+ "WHERE NAME(institutes) = 'institutes' ORDER BY institute.overallScore DESC";
我還發現,PATH()之類不兔崽子實施
感謝它的工作!而且我還發現了另一個簡單的替代方法'select * from [nt:base],其中name()='institute''此查詢從存儲庫中獲取名稱爲institute的所有節點 – reverbnation