To monitor database tables using SQL query, SQL Query monitor can be used. This article gives you an example of how to deploy an SQL query monitor and create a sensor to monitor the facts generated.
- Right-click the CEP server on which you want to deploy the SQL Query Monitor.
- Select Deploy Expert > Probes > SQL Query Monitor.
- On the General tab, enter a name for the SQL Query Monitor being deployed:
- Fill in the Database details on the JDBC Options tab:
- Specify an SQL query on the SQL Query tab:
- Deploy the SQL Monitor.
- The Facts are deployed as shown below:
- Create a new business view. Go to the Sensor Wizard and include the facts you want to monitor and add sensor rules.
- Open the policy. Go to the properties tab for the sensor and select the Logging tab and add or create the database tables.