Note that there are some explanatory texts on larger screens.

plurals
  1. POWhat is the difference between cts:search and cts:element-attribute-values?
    primarykey
    data
    text
    <p>I can't understand deference between <code>cts:search</code> and <code>cts:element-attribute-values</code>. I can get the same result with both these functions. What is the best resolve?</p> <pre><code>cts:search(/t:ancestors-list/t:concept/t:concept-ancestor, cts:element-value-query(xs:QName("t:concept-ancestor"), $concept/id))/@subject </code></pre> <p>or</p> <pre><code>cts:element-attribute-values( xs:QName("t:concept-ancestor"), xs:QName("subject"), (), ("collation=http://marklogic.com/collation/codepoint"), cts:element-value-query( xs:QName("t:concept-ancestor"), $concept/id ) ) </code></pre> <p><strong>ar:concept-ancestor</strong> is the element range index and element attribute range index.</p> <p>And <strong>xml</strong> structure like this</p> <pre><code>&lt;t:ancestors-list xmlns:ar="http://test.com"&gt; &lt;t:concept subject="http://test.com/concept#1c5cd7082ac908c62e9176770ae0fb53"&gt; &lt;t:concept-ancestor subject="http://test.com/concept#1c5cd7082ac908c62e9176770ae0fb53"&gt;4a1f650290103d39863bf7bc22ef18aa&lt;/t:concept-ancestor&gt; &lt;/t:concept&gt; &lt;t:concept subject="http://test.com/concept#05b707457f79f42c93bf778915e4a589"&gt; &lt;t:concept-ancestor subject="http://test.com/concept#05b707457f79f42c93bf778915e4a589"&gt;4a1f650290103d39863bf7bc22ef18aa&lt;/t:concept-ancestor&gt; &lt;t:concept-ancestor subject="http://test.com/concept#05b707457f79f42c93bf778915e4a589"&gt;1c5cd7082ac908c62e9176770ae0fb53&lt;/t:concept-ancestor&gt; &lt;/t:concept&gt; ... &lt;/t:ancestors-list&gt; </code></pre> <p>Thank you!</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload