On 15.07.2019 16:34, Jordan Castillo wrote:
I am noticing that my queries aren't working when I check the value of an attribute who has a colon in the name field. Here is an example:
1: Yields no results let $begin := db:open($documentName) return $begin//packagedElement[@name="auxiliaryResource" and @xmi:id="_12_1_8f90291_1173963323875_662612_98"]
2: Yields no results return $begin//packagedElement[@xmi:id="_12_1_8f90291_1173963323875_662612_98"]
3: Yields expected result: return $begin//packagedElement[@name="auxiliaryResource"]
Example of element I am searching for here: <packagedElement xsi:type="uml:Stereotype" xmi:id="_12_1_8f90291_1173963323875_662612_98" ID="_12_1_8f90291_1173963323875_662612_98" name="auxiliaryResource">
What is the namespace declared for the prefix xmi? You need to declare that in the XQuery code as well.