Parameters

The following parameters are available in a direct JDBC probe.

Parameter Name Description Example Required?
jdbc_driver The Java class name for the JDBC driver to use, the currently supported drivers are
  • Oracle - oracle.jdbc.OracleDriver
  • Microsoft SQL Server - com.microsoft.sqlserver.jdbc.SQLServerDriver
  • MySQL - com.mysql.jdbc.Driver
com.microsoft.sqlserver.jdbc.SQLServerDriver Y
connection_string The JDBC connection string/URL for defining the connection, usually contains information about the database server and name, the user id and password for conenctiong to the database. The syntax is vendor specific, refer to the following links for reference
  • Oracle - [jdbc:oracle:thin:<username/password>@<database>]
  • Microsoft SQL Server - [jdbc:sqlserver://localhost;user=MyUserName;password=*****;]
  • MySQL - [jdbc:mysql://localhost/database?user=username%26password=passwd]
jdbc:sqlserver://xxx.service-now.com;databaseName=SMS;user=sms_user;password=sms_password Y
work A parent element of an XML fragment describing the SQL command to execute
...
  <parameter name= "work" ><select table = "System_DATA" where = "InstanceKey=692" ><MachineID /><SMSID0 /></select></parameter>
  ...
Y (if not using the table_name parameter short cut)
query_timeout Specify the number of seconds the JDBC driver will wait for a query (SELECT) to complete. Zero means no timeout. If timeout is exceeded, the integration considers the JDBC result inaccessible and places it in an error state. 60 N (optional during SELECT)
table_name An alternate way of executing a select * query, instead of using the work element. Equivalent to executing "select * from <table_name>" System_DATA N (required during count_rows == true)
count_rows Indicate the a select count(*) query should be executed returning the number of rows. The result of the count will be returned as a row_count element in the result element. true N
query Indicate the type of query. If the query type is "Specific SQL", the sql_statement will be required to specify the SQL statement. The possible choices are "All Rows from Table" or "Specific SQL". N
sql_statement Use a specific SQL query. The presence of this element will execute a direct query specified in the value attribute. select * from any_table where id = 123 N
skip_sensor Determines if Discovery will attempt to process the ECC input from the JDBCProbe. This parameter defaults to true. true N
For example, to query a table using a direct JDBC probe, requires the following parameters
  • JDBC driver class name
  • JDBC connection string
    • Database server
    • Database name
    • User name
    • User password
  • The table name
Figure 1. Queue form