HI.
This is the general sample people see for which you can build on:
cts:element-query(xs:QName('id'),cts:and-query( () ))
This does into take into count position within the structure - just if the
element exists or not .
An earlier thread with all of the history and example :
http://markmail.org/search/?q=Re%3A%20%5BMarkLogic%20Dev%20General%5D%20check%20element%20existance#query:Re%3A%20%5BMarkLogic%20Dev%20General%5D%20check%20element%20existance+page:1+mid:64mculffepgjsxp7+state:results
Kind Regards,
David Ennis
David Ennis
*Content Engineer*
[image: HintTech] <http://www.hinttech.com/>
Mastering the value of content
creative | technology | content
Delftechpark 37i
2628 XJ Delft
The Netherlands
T: +31 88 268 25 00
M: +31 63 091 72 80
[image: http://www.hinttech.com] <http://www.hinttech.com>
<https://twitter.com/HintTech> <http://www.facebook.com/HintTech>
<http://www.linkedin.com/company/HintTech>
On 10 September 2014 10:42, priya dharshni <[email protected]>
wrote:
>
> Hi ,
>
>
> I want to identify the uris which does not have the particular
> element.Say, i want to get uris which does not have "id' element.
>
> xml in db :
> <employee>
> <name>test</name>
> <id>123</id>
> </employee>
>
> cts:uris(''",
> (),
>
>
>
> cts:not-query(cts:element-value-query(xs:QName("id"),"*"))
> )
> The above query pulls all the uris with and without "id" element.Please
> let me know how to fix this.
>
> Regards,
> Priya.
>
> _______________________________________________
> General mailing list
> [email protected]
> http://developer.marklogic.com/mailman/listinfo/general
>
>
_______________________________________________
General mailing list
[email protected]
http://developer.marklogic.com/mailman/listinfo/general