Hi Bernd,
The good news is that this powerful TWiki feature is nothing compared to the capability of XWiki's search feature! :)
You can do any type of query in xwiki using Velocity. Unfortunately there is very little documentation. However there are lots of examples available on the code zone for example.
Here's an example of a search that looks for all pages that have a XWiki.ReferenceClass object attached and sort the results in ascending order of their name. The results are printed as a list.
#set ($hql = ", BaseObject as obj where obj.name=doc.fullName and obj.className='XWiki.ReferenceClass' and obj.name<>'XWiki.ReferenceClassTemplate' order by doc.name asc")
#foreach ($reference in $xwiki.searchDocuments($hql))
* $reference
#end
But really you can do whatever you want since it translates to a database search. FYI the search syntax is HQL (Hibernate Query Language).
Thanks
-Vincent
On Jan 14, 2008, at 9:12 AM, Bernd Götz wrote:
Hello
I'm using TWiki. TWiki has this really powerfull formatted search capability (see http://twiki.org/cgi-bin/view/TWiki/FormattedSearch). Is there an equivalent to this in XWiki?
An example of a search looks like this:
%SEARCH{ "META\:FORM.*\"TechnologyDomainForm\"" type="regex" nosearch="on" nototal="on" order="topic" reverse="on"
header="| *Domain* | *Description* | *Status* | *Responsible* |"
format="| $topic | $pattern(.*?Summary[\n\r]*([^\n\r]+).*) | $formfield(Domain-Status) | $formfield(Domain-Responsible) |" web="TA"}%
You see that I use a regular expression that checks whether a page as the form with the name "TechnologyDomainForm" attached to it. For all those pages, it returns a table with the specified header and some values: the topic name, some content from the page, and some form field content.
Thanks for your support!
Regards
Bernd