The ConditionSearchNode is constructed as a SQL query statement, where the Left and Right elements are the two sides of the operator.
Return all articles that have the author = 'Armando Trovati'
<SearchConditions
xmlns="http://www.teradp.com/schemas/GN4/1/SearchConditions.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
ObjectTypeName="article">
<SearchNode xsi:type="ConditionSearchNode" Op="Equal">
<Left xsi:type="AttributeSearchNode" Path="article.authors"/>
<Right xsi:type="StringSearchNode" Value="Armando Trovati" />
</SearchNode>
</SearchConditions>
The search condition above returns all articles that have an author = 'Armando Trovati'.
Assuming this search condition has been loaded into the database from the file Search_articleAuthor.xml, the search is executed with a statement such as:
http://localhost/tark4/do.ashx?cmd=search&name=articleAuthor
Assuming the search condition has been saved in the file Search_articleAuthor.xml in the same folder where cm4 resides, you can execute it in cmd4 as:
C:\tera\GN4\main\bin>cmd4 get -conditions search_articleAuthor.xml -out output.xml -username bruno -password ifra
It stores results in the output.xml file.
See also