Database Reference
In-Depth Information
<value key= "product_model" > SomeName|SomeCode12345 </value>
into:
<value key= "product_model" >
<product_name> SomeName </product_name>
<product_code> SomeCode12345 </product_code>
</value>
The trigger takes two parameters:
separator
The character or string that separates the text values that you wish to split
into multiple element text values.
path
An expression similar to a simple XPath expression, and a list of extractions
to perform. You may provide as many path parameters as you wish.
For example, for you to achieve the preceding example split, the collection con‐
figuration for the CSV extracting trigger would look like:
<collection xmlns= "http://exist-db.org/collection-config/1.0" >
<triggers>
<trigger class= "org.exist.collections.triggers.CSVExtractingTrigger" >
<parameter name= "separator" value= "|" />
<parameter name= "path" >
<xpath> /content/properties/value[@key eq "product_model"] </xpath>
<extract index= "0" element-name= "product_name" />
<extract index= "1" element-name= "product_code" />
</parameter>
</trigger>
</triggers>
</collection>
History
The trigger org.exist.collections.triggers.HistoryTrigger can be used to
create an archive copy of a resource before it is deleted or overwritten. For
details, see “Versioning” on page 427 .
Replication
For the emerging database replication support in eXist, the trigger
org.exist.replication.jms.publish.ReplicationTrigger publishes details of
all database operations to a JMS topic.
RESTXQ
The RESTXQ implementation in eXist uses the trigger org.exist.exten
sions.exquery.restxq.impl.RestXqTrigger to compile XQuery modules after
they are stored into the database. It then examines the compiled XQuery for
resource functions, and any it finds are registered with the RESTXQ resource
Search WWH ::




Custom Search