Expand my Community achievements bar.

Who Me Too'd this topic

Avatar

Level 4

I am trying to query the database through a script in a web app, but when providing the country location in the database, it is throwing an error. The folder is gmlocation/country under recipients. This is the error below.

Attribute 'country' unknown (see definition of schema 'Recipients (nms:recipient)'). XTK-170036 Unable to parse expression '@country='CAN''. SOP-330011 Error while executing the method 'ExecuteQuery' of service 'xtk:queryDef'.

 

Here is an sample of the script I am trying to query.

var query = xtk.queryDef.create(
  
  <queryDef schema="nms:recipient" operation="getIfExists">
    
    <select>
   
      <node expr="@email"/>
      
      <node expr="@id"/>
    
    </select>
   
    <where>
    
    <condition expr={"@email='"+ctx.recipient.@email+"'"}/>
    <condition expr={"@sourceType='Media'"}/>
    <condition expr={"@country='CAN'"}/>
     
    </where>
    </queryDef>
Who Me Too'd this topic