EventToDB

Wed May 27 04:16:48 EDT 2009

This handler can be used to store data parsed from events into a database. You define an SQL statement that contains event variables (surrounded by '%') to be dereferenced when executed, for example:

INSERT INTO table ( cust_name, rank ) VALUES ( "%customer%", %ranking% );

The list of variables available for replacement depends on where the event traversed the rule tree, and the variables you defined at each rule tree node.

WARNING: If an event is not parsed as you expected (e.g. a corrupted or unknown event was received) then some variable replacements may not succeed. This handler can simply leave any unmatched variables in your SQL. This can sometimes be useful since it documents what is missing (i.e. a named variable). However, if it corrupts your SQL statement causing an error, then Augur will disable the handler instance until it is re-initialized (e.g. when you change the handler's properties in the editor). So you may want to set allowFailedReplacement=false to ensure that the handler simply skips statements that failed to complete one or more replacements.