Icon

Comments have been closed on this page. Please use AppMon & UEM Plugins forum for questions about this plugin.

Overview

 
The monitor returns the row count from the specified query and up to 10 column values of the "top" row if desired (must be numeric value). There is also an additional measure detailing whether the connection to the database was successful or not

Plugin Details

Plug-In Versions

DB Query Monitor Plugin 3.1.0 (tested with 5.5)

DB Query Monitor Plugin 3.2.0 (added support for Ingres 9.x and Ingres 10.x - tested with dT 5.5)

DB Query Monitor Plugin 3.2.1 (added support for PostgreSQL - dynatrace >5.5)

DB Query Monitor Plugin 3.2.2 (Added support for MySQL and IBM Netezza)

DB Query Monitor Plugin 3.2.4 (Adds configuration to specify Oracle connection using SID or Service Name)

Author

Derek Abing (v 2.0.0)

James Mackin (v.3.0.0+)

Derick Hewetson and Yusuf Bata (v.3.2.1)

Ben Goff and Jacob Payne (v.3.2.2)

James Kitson (v.3.2.4)

License

dynaTrace BSD

Support

Not Supported
If you have any questions or suggestions for these plugins, please add a comment to this page, use our forum, or drop us an email at community@dynatrace.com!

Known Problems

 

Release History

2013-05-23 Initial Release by Derek Abing

2013-09-16 Version 3.0.0 provided by James Mackin now provides up to 10 result columns

2013-09-23 Version 3.1.0 provided by James Mackin with addition configuration options and result measures

2013-10-19 Version 3.2.0 provided by Steve Caron with support for Ingres 9.x & 10.x

2014-10-20 Version 3.2.1 provided by Derick Hewetson and Yusuf Bata with support for PostgreSQL

2015-07-06 Version 3.2.2 provided by Ben Goff and Jacob Payne with support for MySQL and IBM Netezza

2017-09-08 Version 3.2.4 provided by James Kitson configuration to specify connections to Oracle should use SID or Service Name

 

Configuration

Name

Value

SQL Type

Select if you want to query MS SQL Server, Oracle, MySQL, IBM DB2, IBM Netezza, Postgres, or Ingres

SQL Port

SQL Port to use on the SQL Server

Oracle Connection Method (since v.3.2.4)Should the generated string use the SID or Service Name format when connecting to Oracle databases

Database

Name of the database to connect to on the sql server

SQL Statement

SQL Statement to execute on the SQL database. The returned rows of this statement will be used for the monitor.

Windows Logon

If checked, the program will use windows single sign-on and use the credentials associated with the Collector.

SQL Username

Username to use for login to the database (SQL Server Authentication)

SQL Password

Password for the username used to connect to the sql database (SQL Server Authentication)

Capture Column Data

If this box is checked you can capture the value of the top row of a specific column. If this value is set, the query should ensure that the first record contains the pertinent data. The result set should also only contain one record, unless the row count is also important to track.

Query Timeout (since v 3.0.0)The query timeout period, in seconds. The query will be cancelled after this time and the total response time returned as a measure, which can then be alerted on 
Query Name (since v 3.0.0)A readable short name used to identify the query in this monitor instance 
Column Name (since v 3.0.0)The name of the first column whose value should be returned. The returned value must be numeric 
Column Name 2 (since v 3.0.0)The name of the second column whose value should be returned. The returned value must be numeric. If this column and any other subsequent columns are specified, then the values will be returned as dynamic measures, scoped by the Query Name 
Column Name 3 - 10 (since v 3.0.0)The name of the 3rd - 10th columns whose values should be returned
Match Content (since v 3.1.0)If this box is checked then two more configuration items become available to enter: a column name to compare against a constant value, and the constant value itself.
Match Column (since v 3.1.0)The name of the column in the result set to match against
Match Value (since v 3.1.0)The value, or regular expression, the column needs to be compared to. If the two values are equal the 'Content Verified' measure will be set to 1. Otherwise it will be set to 0.

 

***WARNING - The datatype of the column must be numeric!***

Measures

Column Value

The value of the captured column as a regular measure. Will contain the value of the first column returned, if the Capture Column Data column is checked.

If multiple column names are specified, then this measure can be selected and then split the measures based on the specified Query Name property

DB Connection

Returns a 1 if the DB connection was successful and a 0 if the DB connection failed or if the query didn’t finish within the Query Timeout number of seconds

Row Count

Number of rows returned in the query

Response Time (since v 3.0.0)The total time, in milliseconds, that it took to connect to the database, execute the query, and close the database connection. 
Connect Response Time (since v 3.0.0)The total time, in milliseconds, that it took to connect to the database.
Query Response Time (since v 3.0.0)The total time, in milliseconds, that it took to execute the query.
Content Verified (since v 3.1.0)1 if the Match Content flag is checked, and the Match Value and the contents of the Match Column are equivalent.

Installation

Import the Plugin into the dynaTrace Server. For details how to do this please refer to the dynaTrace documentation.

Contribution

Feel free to contribute any changes on Github

  1. Anonymous (login to see details)

    I tried using the plugin to query an oracle DB but it gave a "plugin internal error" when trying to execute the monitor, failure reason unknown...
    I am not sure whether I configured something wrong or if the agent used must be on the DB Server, there is very little one can make mistakes with configuring the monitor and I can't tell what the error is!

    1. Anonymous (login to see details)

      For Oracle, you will need to specifiy the SQL username and password to use. Depending on your environment, ensure that there is no firewall blocking the communication. Every plugin has a log file under the Collector installation directory, check there to see if there is anything being logged that might diagnose the issue.

  2. Anonymous (login to see details)

    Works well with Oracle, thanks! would it be possible to add the drivers/option for Ingres?

    1. Anonymous (login to see details)

       

      Thanks for the 3,2 update - works well with 5.5

  3. Anonymous (login to see details)

    How can i use and implement this plugin, i'm starting to learning about plugins and this stuff

     

    1. Anonymous (login to see details)

      After you install the plugin, you would set it up as a monitor.  Monitors can be added via the Monitor sections of the System Profile.  If you need any help with configuration just ask.

       

      Thanks,

      Brian

       

       

  4. Anonymous (login to see details)

    I want to see number of rows returned by the query for Oracle database.Please give me example with screenshots.

    1. Anonymous (login to see details)

      Hi Joshi

      I guess all you need to do is to setup this monitor and for the SQL Statement you use something like: "SELECT Count( * ) FROM TABLE WHERE ..." - The Count ( * ) will return the number of rows returned by that query. The DB Query Monitor Plugin will then return this number as a measure that you can use for charting, incidents, ...

  5. Anonymous (login to see details)

    Thanks for replying.I tried it but it is not working.Will you please send me some screenshots of configuration.

     

    1. Anonymous (login to see details)

      Just have a look at the first screenshot that shows the configuration of the Monitor - and there just make sure that you use the correct SQL Statement that starts with "Select COUNT ( * )"

      1. Anonymous (login to see details)

        Hi Andreas,

         

        By going through the log of monitor I found :


            at oracle.net.ns.NSProtocol.connect(NSProtocol.java:395)
            at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1102)
            at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:320)
            ... 20 more
        2013-12-17 16:01:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6180622.7679779995
        2013-12-17 16:02:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6240625.063242

        Please advice me over this.

        1. Anonymous (login to see details)

          Seems like there is a problem connecting to your database. Are you sure that

          a) you have provided the correct connection settings for your database, e.g: server, username, pwd, ...

          b) that the machine that this monitor runs on (thats the Collector) - really has access to your database?

          What database and version do you want to connect to? Is it Oracle? If so - which version exactly?

          1. Anonymous (login to see details)

            Hi Andreas,

            I am using Oracle Database 10g Enterprise Edition Release 10.2.0.1.0.

            The configuration details are:

            SQL type="Oracle"

            SQL port=1521

            Database="CALLLOG"

            URL=jdbc:oracle:thin:@webapp_org:1521:CALLLOG/CALLLOG@WEBAPP

            SQL Statement=SELECT COtUNT(*) AS COUNT FROM CALLLOG.PRODUCT WHERE STATUS = 'unsaved';

            SQL USERNAME=CALLLOG

            SQL Password=

            Query name=Qstat

            Column name=count

            My database is on another machine and I have the access to the database.

             

            1. Anonymous (login to see details)

              Could you please share you entire log file? The snippet above seems to miss the actual error message...

              In addition, the SQL statement "SELECT COtUNT(*) AS COUNT FROM CALLLOG.PRODUCT WHERE STATUS = 'unsaved';" should probably read "SELECT COUNT(...)" and not COtUNT

              1. Anonymous (login to see details)

                Actually there is spelling mistake in previous reply but query in the monitor configuration is right.

                I am sending you the complete log.


                 
                    at oracle.net.ns.NSProtocol.connect(NSProtocol.java:395)
                    at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1102)
                    at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:320)
                    ... 20 more
                2013-12-17 15:29:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4260626.914315
                2013-12-17 15:30:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4320626.229591
                2013-12-17 15:31:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4380625.778136999
                2013-12-17 15:32:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4440626.130416
                2013-12-17 15:33:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4500626.189363
                2013-12-17 15:34:20 INFO [QMonitor@New DB Query Monitor_0] Previous message was repeated 17 times.
                2013-12-17 15:34:20 INFO [QMonitor@New DB Query Monitor_0] Connecting to Oracle database: jdbc:oracle:thin:@webapp_org:1521:CALLLOG/CALLLOG@WEBAPP
                2013-12-17 15:34:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4560626.014200999
                2013-12-17 15:35:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4620626.924372
                2013-12-17 15:36:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4680625.173591
                2013-12-17 15:37:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4740625.982911999
                2013-12-17 15:38:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4800625.733717999
                2013-12-17 15:39:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4860625.798251
                2013-12-17 15:40:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4920625.488156
                2013-12-17 15:41:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -4980625.1076609995
                2013-12-17 15:42:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5040625.09481
                2013-12-17 15:43:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5100625.570569
                2013-12-17 15:44:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5160625.334226
                2013-12-17 15:45:20 SEVERE [QMonitor@New DB Query Monitor_0] Previous message was repeated 15 times.
                2013-12-17 15:45:20 SEVERE [QMonitor@New DB Query Monitor_0] java.sql.SQLException: Listener refused the connection with the following error:
                ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
                 
                    at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:458)
                    at oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:546)
                    at oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:236)
                    at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
                    at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:521)
                    at java.sql.DriverManager.getConnection(DriverManager.java:582)
                    at java.sql.DriverManager.getConnection(DriverManager.java:154)
                    at com.db.monitor.QueryMonitor.execute(QueryMonitor.java:139)
                    at com.db.monitor.QMonitor.execute(QMonitor.java:30)
                    at com.dynatrace.diagnostics.sdk.UserPluginManager.executePlugin(SourceFile:565)
                    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:52)
                    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:27)
                    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:192)
                    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:415)
                    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.execute(SourceFile:339)
                    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.a(SourceFile:101)
                    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.work(SourceFile:92)
                    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.executeJobInfo(SourceFile:241)
                    at com.dynatrace.diagnostics.scheduling.impl.QuartzJob.execute(SourceFile:45)
                    at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
                    at com.dynatrace.diagnostics.scheduling.impl.QuartzThreadPool$WorkerThread.run(SourceFile:788)
                Caused by: oracle.net.ns.NetException: Listener refused the connection with the following error:
                ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
                 
                    at oracle.net.ns.NSProtocol.connect(NSProtocol.java:395)
                    at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1102)
                    at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:320)
                    ... 20 more
                2013-12-17 15:45:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5220624.776334
                2013-12-17 15:46:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5280624.4193049995
                2013-12-17 15:47:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5340624.972448
                2013-12-17 15:48:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5400627.478352999
                2013-12-17 15:49:20 INFO [QMonitor@New DB Query Monitor_0] Previous message was repeated 14 times.
                2013-12-17 15:49:20 INFO [QMonitor@New DB Query Monitor_0] Connecting to Oracle database: jdbc:oracle:thin:@webapp_org:1521:CALLLOG/CALLLOG@WEBAPP
                2013-12-17 15:49:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5460638.691509999
                2013-12-17 15:50:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5520624.130162
                2013-12-17 15:51:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5580625.09928
                2013-12-17 15:52:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5640627.49316
                2013-12-17 15:53:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5700624.127648
                2013-12-17 15:54:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5760628.004118
                2013-12-17 15:55:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5820624.14441
                2013-12-17 15:56:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5880624.765718
                2013-12-17 15:57:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -5940623.660829
                2013-12-17 15:58:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6000623.934607
                2013-12-17 15:59:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6060623.208257
                2013-12-17 16:00:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6120623.824816
                2013-12-17 16:01:20 SEVERE [QMonitor@New DB Query Monitor_0] Previous message was repeated 15 times.
                2013-12-17 16:01:20 SEVERE [QMonitor@New DB Query Monitor_0] java.sql.SQLException: Listener refused the connection with the following error:
                ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
                 
                    at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:458)
                    at oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:546)
                    at oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:236)
                    at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
                    at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:521)
                    at java.sql.DriverManager.getConnection(DriverManager.java:582)
                    at java.sql.DriverManager.getConnection(DriverManager.java:154)
                    at com.db.monitor.QueryMonitor.execute(QueryMonitor.java:139)
                    at com.db.monitor.QMonitor.execute(QMonitor.java:30)
                    at com.dynatrace.diagnostics.sdk.UserPluginManager.executePlugin(SourceFile:565)
                    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:52)
                    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:27)
                    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:192)
                    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:415)
                    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.execute(SourceFile:339)
                    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.a(SourceFile:101)
                    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.work(SourceFile:92)
                    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.executeJobInfo(SourceFile:241)
                    at com.dynatrace.diagnostics.scheduling.impl.QuartzJob.execute(SourceFile:45)
                    at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
                    at com.dynatrace.diagnostics.scheduling.impl.QuartzThreadPool$WorkerThread.run(SourceFile:788)
                Caused by: oracle.net.ns.NetException: Listener refused the connection with the following error:
                ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
                 
                    at oracle.net.ns.NSProtocol.connect(NSProtocol.java:395)
                    at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1102)
                    at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:320)
                    ... 20 more
                2013-12-17 16:01:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6180622.7679779995
                2013-12-17 16:02:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6240625.063242
                2013-12-17 16:03:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6300624.032384
                2013-12-17 16:04:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6360622.629412999
                2013-12-17 16:05:20 INFO [QMonitor@New DB Query Monitor_0] Previous message was repeated 15 times.
                2013-12-17 16:05:20 INFO [QMonitor@New DB Query Monitor_0] Connecting to Oracle database: jdbc:oracle:thin:@webapp_org:1521:CALLLOG/CALLLOG@WEBAPP
                2013-12-17 16:05:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6420624.760131
                2013-12-17 16:06:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6480622.988956
                2013-12-17 16:07:10 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6529983.492594999
                2013-12-17 16:07:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6539964.098789999
                2013-12-17 16:07:30 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6549979.922309
                2013-12-17 16:07:40 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6559964.158294
                2013-12-17 16:07:50 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6569964.020567
                2013-12-17 16:08:00 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6579979.635679999
                2013-12-17 16:08:10 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6589964.023081999
                2013-12-17 16:08:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6599979.62702
                2013-12-17 16:08:30 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6609964.082866
                2013-12-17 16:08:40 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6619981.969217
                2013-12-17 16:08:50 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6629963.977824
                2013-12-17 16:09:00 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6639964.029507
                2013-12-17 16:09:10 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6649979.677026
                2013-12-17 16:09:20 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6659963.965253
                2013-12-17 16:09:30 WARNING [QMonitor@New DB Query Monitor_0] Calculated a negative connection duration of -6669979.623109

                1. Anonymous (login to see details)

                  Thanks, it looks like the actual error is

                  ORA-12505, TNS:listener does not currently know of SID given in connect descriptor

                  which looks like to me like your connection string is not correct. I'm not the resident Oracle expert, but Google brings up a lot of pages like http://stackoverflow.com/questions/18192521/ora-12505-tnslistener-does-not-currently-know-of-sid-given-in-connect-descript - maybe there's some insight there?

  6. Anonymous (login to see details)

    Hello,

     

    i found this logs.

    2013-12-18 10:09:40 SEVERE [QMonitor@GAURAV_New DB Query Monitor_1] java.sql.SQLException: ORA-00911: invalid character
        at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:445)
        at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:396)
        at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:879)
        at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:450)
        at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:192)
        at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:531)
        at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:193)
        at oracle.jdbc.driver.T4CStatement.executeForDescribe(T4CStatement.java:866)
        at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:1167)
        at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1289)
        at oracle.jdbc.driver.OracleStatement.executeQuery(OracleStatement.java:1491)
        at oracle.jdbc.driver.OracleStatementWrapper.executeQuery(OracleStatementWrapper.java:406)
        at com.db.monitor.QueryMonitor.execute(QueryMonitor.java:168)
        at com.db.monitor.QMonitor.execute(QMonitor.java:30)
        at com.dynatrace.diagnostics.sdk.UserPluginManager.executePlugin(SourceFile:565)
        at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:52)
        at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:27)
        at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:192)
        at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:415)
        at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.execute(SourceFile:339)
        at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.a(SourceFile:101)
        at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.work(SourceFile:92)
        at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.executeJobInfo(SourceFile:241)
        at com.dynatrace.diagnostics.scheduling.impl.QuartzJob.execute(SourceFile:45)
        at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
        at com.dynatrace.diagnostics.scheduling.impl.QuartzThreadPool$WorkerThread.run(SourceFile:788)
    2013-12-18 10:09:50 INFO [QMonitor@GAURAV_New DB Query Monitor_0] Connecting to Oracle database: jdbc:oracle:thin:@192.168.3.243:1521:ORCL
    2013-12-18 10:09:50 INFO [QMonitor@GAURAV_New DB Query Monitor_1] Connecting to Oracle database: jdbc:oracle:thin:@192.168.3.243:1521:ORCL
    2013-12-18 10:09:50 INFO [QMonitor@GAURAV_New DB Query Monitor_0] Executing SQL: Select count(*) from product where status='saved';

     

    please suggest over this.

     

    1. Anonymous (login to see details)

      Hi Prathamesh! Sounds like you're one step further (smile) Could you try it without the semicolon at the end?

  7. Anonymous (login to see details)

    The DT documentation link is not working. I have added it to the plugins folder of my DT directory but still not able to see the DB Query Monitor. Can someone help me on how can i get it? I am using DT 4.2

    1. Anonymous (login to see details)

      Hi. I fixed the doc link. It should go here: Manage and Develop User Plugins

      All you need to do is to go to your Server Settings Dialog -> Plugins and there Install the Plugin by clicking the Install Plugin button

  8. Anonymous (login to see details)

    Hi,

    i found this in my logs:

    2014-07-24 11:03:43 SEVERE [QMonitor@IS13_IDU_LoadSelectionDialog_0] java.sql.SQLException: ORA-01843: not a valid month

    the sql statement is:

    select * from (select duration from mb_usecase_trace where to_date(to_char(starttime, 'MM/DD/YYYY HH24')) = to_char(sysdate, 'MM/DD/YYYY HH24') and modulename = 'DPL_IOPT' and lower(usecase) like 'loadselectiondialog' order by starttime desc) WHERE rownum <= 1

     

    Can anyone see the mistake?

    1. Anonymous (login to see details)

      i solve the problem.

      1. Anonymous (login to see details)

        Can you let us know what the problem was? Would be interesting to learn what the mistake was.

  9. Anonymous (login to see details)

    Hi,

    Are there any ways to get this plugin to work with PostgreSQL?

    Thanks.

  10. Anonymous (login to see details)

    Hi,

    I want to monitor an Oracle RAC database, where I need to query 3 IP addresses, not just 1, in order to verify the content of a database. Does anyone know of a way to do this? Oracle won't allow me to just query one of the three addresses, as it is effectively load-balancing, and will redirect me to any of the three addresses every time I connect.

     

    Thanks,

    Derick

    1. Anonymous (login to see details)

      Hi Derek. you may want to post this question to the dynaTrace Open Q&A Forum as well. The questions here on the download page are probably not monitored by that many people as compared to the forum. Chances to get an answer are therefore higher. I will however forward this question internally and see what our engineers have to say

  11. Anonymous (login to see details)

    Hi Derick,

    I've done this in the past with BSM (ie not with this plugin but its just JDBC).  Requires a different url, quite complex if I recall and it listed each node i the RAC cluster.

    I'd guess this covers it.

    http://stackoverflow.com/questions/1646630/jdbc-what-is-the-correct-jdbc-url-to-connect-to-a-rac-database

    Looking at the code (see method setConnectionConfig) I can see this plugin uses a property called URL and that will allow you to override the product specific settings (ie oracle, sql server etc) but the docs don't cover it.  You must still pass a valid SQLType even though its not really used.  Sorry I can't provide a fuller  example at the moment.

    If you aren't aware you can install the plugin and extract the source code from it using the export feature (or just unzip it).  Then modify it and redeploy in your dT system.  All quite straight forward and this plugin is actually quite simple as well, just two classes.

     

    regards,

    Alex.

  12. Anonymous (login to see details)

    Hi, it would be good to properly report all types of SQL exceptions as failed task executions, currently these seem to be swallowed sometimes and not reported to the monitor execution framework of dynaTrace which means that you do not see that the monitor failed to run completely, only the logfile has some information about the failure.

    E.g. I had this when things like URL or username/password are not correctly specified.

    1. Anonymous (login to see details)

  13. Anonymous (login to see details)

    Hello,

    We have the plugin setup to pull back Oracle metrics using SQL Authentication without any issues. We're now working on setting up the plugin to pull back MSSQL metrics using Windows Authentication but we're receiving the following exceptions in the plugin logs:

     

    2014-10-02 16:43:41 INFO [QMonitor@LDR - Near Real time MONITOR_0] Connecting to Microsoft SQL Server database: jdbc:sqlserver://hostname.fqdn.com:1435;databaseName=databasename;integratedSecurity=true;
    2014-10-02 16:43:56 SEVERE [QMonitor@LDR - Near Real time MONITOR_0] com.microsoft.sqlserver.jdbc.SQLServerException: This driver is not configured for integrated authentication. ClientConnectionId:6bfa08f9-dbd0-4259-90e0-107371391a94
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.terminate(SQLServerConnection.java:1667)
    at com.microsoft.sqlserver.jdbc.AuthenticationJNI.<init>(AuthenticationJNI.java:60)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.logon(SQLServerConnection.java:2229)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.access$000(SQLServerConnection.java:41)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection$LogonCommand.doExecute(SQLServerConnection.java:2220)
    at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:5696)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:1715)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:1326)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.login(SQLServerConnection.java:991)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:827)
    at com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:1012)
    at java.sql.DriverManager.getConnection(DriverManager.java:571)
    at java.sql.DriverManager.getConnection(DriverManager.java:233)
    at com.db.monitor.QueryMonitor.execute(QueryMonitor.java:133)
    at com.db.monitor.QMonitor.execute(QMonitor.java:30)
    at com.dynatrace.diagnostics.sdk.UserPluginManager.executePlugin(SourceFile:565)
    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:52)
    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:27)
    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:192)
    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:415)
    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.execute(SourceFile:339)
    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.a(SourceFile:101)
    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.work(SourceFile:92)
    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.executeJobInfo(SourceFile:241)
    at com.dynatrace.diagnostics.scheduling.impl.QuartzJob.execute(SourceFile:45)
    at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
    at com.dynatrace.diagnostics.scheduling.impl.QuartzThreadPool$WorkerThread.run(SourceFile:788)
    Caused by: java.lang.UnsatisfiedLinkError: no sqljdbc_auth in java.library.path
    at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1886)
    at java.lang.Runtime.loadLibrary0(Runtime.java:849)
    at java.lang.System.loadLibrary(System.java:1088)
    at com.microsoft.sqlserver.jdbc.AuthenticationJNI.<clinit>(AuthenticationJNI.java:35)
    ... 25 more

     

    Any guesses as to what to try? Thanks!

    1. Anonymous (login to see details)

      Jarryd,

       

      If the Windows Authentication for this plugin still functions the way I originally set it up to, you need to add the sqljdbc_auth.dll file to the <dt home>\jre\bin directory of the dynaTrace Collector.  This is due to the fact that dynaTrace's compilier does not allow you to add DLLs to the build path correctly.

       

      Thanks,

      Brian Perrault

      1. Anonymous (login to see details)

        That was exactly what I needed.

        Thanks Brian!

  14. Anonymous (login to see details)

    Hi,

    I would like to use this plugin with a PostgreSQL database. What would I need to change to accomplish this? As far as I can tell, I'd need a JDBC driver, and would have to add the necessary configuration options.

    Thanks,

    Derick

  15. Anonymous (login to see details)

    I may have found a bug in this plugin. 

    I was testing out the "Match Content" option. I was testing to make sure the value for "Content Verified" returned a 0 when the connection to the database. I changed the DB port to an invalid number to make sure the connection failed but the "Content Verified" measure still returned a 1

    Let me know your thoughts. Thanks!

    1. Anonymous (login to see details)

      I have noticed this too. I get around it by adjusting the incident rule to check the DBConnection too, so it alerts if either drops to zero.

  16. Anonymous (login to see details)

    The monitor runs are always GREEN! no errors about DB connection or query errors..Not very convenient to check run details to make sure if it fails or succeeds.

  17. Anonymous (login to see details)

    Hi, I am trying to run the below query, 

    select REC_PRCS_STAT_CODE as code, COUNT(*) as count from bsns_rec where job_exec_id='4005' group by REC_PRCS_STAT_CODE;

    But, i am not getting any value or errors / exceptions. Kindly advice. Below is the log retrieved in FINER mode:

     

    2015-02-17 19:32:27 FINE [QMonitor@Q1_DB_Query_Monitor_0] Rowcount: 0
    2015-02-17 19:32:27 FINE [QMonitor@Q1_DB_Query_Monitor_0] Elapsed Response Time (milliseconds): 4.160794
    2015-02-17 19:32:27 FINE [QMonitor@Q1_DB_Query_Monitor_0] Elapsed Query Response Time (milliseconds): 4.850211274708E7
    2015-02-17 19:32:27 FINE [QMonitor@Q1_DB_Query_Monitor_0] Setting dynamic measure String->code, value 0.0
    2015-02-17 19:32:27 FINE [QMonitor@Q1_DB_Query_Monitor_0] Setting dynamic measure String->count, value 0.0
    2015-02-17 19:32:27 FINE [QMonitor@Q1_DB_Query_Monitor_0] Setting DB Query Column Value measure with value 0.0
    2015-02-17 19:32:37 FINE [QMonitor@Q1_DB_Query_Monitor_0] Rowcount: 0
    2015-02-17 19:32:37 FINE [QMonitor@Q1_DB_Query_Monitor_0] Elapsed Response Time (milliseconds): 3.389887
    2015-02-17 19:32:37 FINE [QMonitor@Q1_DB_Query_Monitor_0] Elapsed Query Response Time (milliseconds): 4.851209696819E7
    2015-02-17 19:32:37 FINE [QMonitor@Q1_DB_Query_Monitor_0] Setting dynamic measure String->code, value 0.0
    2015-02-17 19:32:37 FINE [QMonitor@Q1_DB_Query_Monitor_0] Setting dynamic measure String->count, value 0.0
    2015-02-17 19:32:37 FINE [QMonitor@Q1_DB_Query_Monitor_0] Setting DB Query Column Value measure with value 0.0

  18. Anonymous (login to see details)

    Hi,

    great plugin. Would be great if the SQL statement could also have an option as it is for the URL "edit URL". An option "edit SQL" with a bigger text field would be good I think.

    I also have the problem on customer side that we configured everything correctly (no exceptions in the log, monitor is green, I see execution in the log), however I dont have values for e.g. row count and column count (just response time gave a measure which indicates that the connection seems to work). I  tried both SQL statements (select of the specific id or table and select count ( * ) ). No success. Also: select count ( * ) does not make too much sense to me because I want to have the row count of the result set and not the row count given by the select statement, right?

    Best regards,
    Dennis

    1. Anonymous (login to see details)

      The issue was found. The "capture column data" checkbox has to be activated and a count( * ) has to be added for the first column...

  19. Anonymous (login to see details)

    Would it be possible to get this plugin updated to work with IBM Netezza DBs?  

  20. Anonymous (login to see details)

    We are not getting "capture column data".  Even changing the query below to a simple query to bring back any captured column data value will only return zero. Are we missing something? The DB is DB2. Thanks

     

    2015-07-07 11:07:18 INFO [QMonitor@COF DB Query Monitor Prod_0] Executing SQL: select count(*) from (SELECT OM_TROUBLE_ID, OM_CAMPAIGN_NAME FROM CNT.OUTAGE_MESSAGES WHERE OM_SENT_DATETIME >= current timestamp - 24 hours and OM_UNSENT_REASON is null GROUP BY OM_TROUBLE_ID, OM_CAMPAIGN_NAME HAVING COUNT(*) >= 1);
    2015-07-07 11:07:18 SEVERE [QMonitor@COF DB Query Monitor Prod_0] com.ibm.db2.jcc.am.vo: DB2 SQL Error: SQLCODE=-104, SQLSTATE=42601, SQLERRMC=;;AVING COUNT(*) >= 1);END-OF-STATEMENT, DRIVER=4.8.87
    at com.ibm.db2.jcc.am.gd.a(gd.java:676)
    at com.ibm.db2.jcc.am.gd.a(gd.java:60)
    at com.ibm.db2.jcc.am.gd.a(gd.java:127)
    at com.ibm.db2.jcc.am.wm.c(wm.java:2510)
    at com.ibm.db2.jcc.am.wm.d(wm.java:2498)
    at com.ibm.db2.jcc.am.wm.a(wm.java:1978)
    at com.ibm.db2.jcc.t4.fb.g(fb.java:140)
    at com.ibm.db2.jcc.t4.fb.a(fb.java:40)
    at com.ibm.db2.jcc.t4.t.a(t.java:32)
    at com.ibm.db2.jcc.t4.ub.i(ub.java:135)
    at com.ibm.db2.jcc.am.wm.hb(wm.java:1949)
    at com.ibm.db2.jcc.am.wm.a(wm.java:2968)
    at com.ibm.db2.jcc.am.wm.a(wm.java:659)
    at com.ibm.db2.jcc.am.wm.executeQuery(wm.java:643)
    at com.db.monitor.QueryMonitor.execute(QueryMonitor.java:177)
    at com.db.monitor.QMonitor.execute(QMonitor.java:30)
    at com.dynatrace.diagnostics.sdk.UserPluginManager.executePlugin(SourceFile:565)
    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:51)
    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:26)
    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:189)
    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.a(SourceFile:412)
    at com.dynatrace.diagnostics.scheduling.impl.ServerJobCenterRegistry.execute(SourceFile:336)
    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.a(SourceFile:101)
    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.work(SourceFile:92)
    at com.dynatrace.diagnostics.scheduling.impl.SchedulerJob.executeJobInfo(SourceFile:241)
    at com.dynatrace.diagnostics.scheduling.impl.QuartzJob.execute(SourceFile:45)
    at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
    at com.dynatrace.diagnostics.scheduling.impl.QuartzThreadPool$WorkerThread.run(SourceFile:788)
    2015-07-07 11:07:18 FINE [QMonitor@COF DB Query Monitor Prod_0] Rowcount: 0
    2015-07-07 11:07:18 FINE [QMonitor@COF DB Query Monitor Prod_0] Elapsed Response Time (milliseconds): 27.258632
    2015-07-07 11:07:18 FINE [QMonitor@COF DB Query Monitor Prod_0] Elapsed Connect Response Time (milliseconds): 17.477988
    2015-07-07 11:07:18 FINE [QMonitor@COF DB Query Monitor Prod_0] Elapsed Query Response Time (milliseconds): 9.780643999999999
    2015-07-07 11:07:18 FINE [QMonitor@COF DB Query Monitor Prod_0] Setting DB Query Column Value measure with value 0.0
    2015-07-07 11:07:19 INFO [QMonitor@COF DB Query Monitor Prod_0] Connecting to IBM DB2 database: jdbc:db2://pdb22db.dteco.com:50252/p242
    2015-07-07 11:07:19 FINER [Driver@COF DB Query Monitor Prod_0] ENTRY Arguments not traced.
    2015-07-07 11:07:19 FINER [Driver@COF DB Query Monitor Prod_0] RETURN null
    2015-07-07 11:07:19 INFO [QMonitor@COF DB Query Monitor Prod_0] Executing SQL: select count(*) from (SELECT OM_TROUBLE_ID, OM_CAMPAIGN_NAME FROM CNT.OUTAGE_MESSAGES WHERE OM_SENT_DATETIME >= current timestamp - 24 hours and OM_UNSENT_REASON is null GROUP BY OM_TROUBLE_ID, OM_CAMPAIGN_NAME HAVING COUNT(*) >= 1);
    2015-07-07 11:07:19 FINE [QMonitor@COF DB Query Monitor Prod_0] Rowcount: 0
    2015-07-07 11:07:19 FINE [QMonitor@COF DB Query Monitor Prod_0] Elapsed Response Time (milliseconds): 27.068036
    2015-07-07 11:07:19 FINE [QMonitor@COF DB Query Monitor Prod_0] Elapsed Connect Response Time (milliseconds): 13.394091999999999
    2015-07-07 11:07:19 FINE [QMonitor@COF DB Query Monitor Prod_0] Elapsed Query Response Time (milliseconds): 13.673943999999999
    2015-07-07 11:07:19 FINE [QMonitor@COF DB Query Monitor Prod_0] Setting DB Query Column Value measure with value 0.0

    1. Anonymous (login to see details)

      According to that SQL error, DB2 seems to think that statement has an illegal character or token in it (see this IBM Knowledge Center article). The SQLERRMC message highlights the part DB2 thinks is the problem: ";;AVING COUNT(*) >= 1);"

       For your simple query, are you using a setup similar to the one shown below?

  21. Anonymous (login to see details)

    Our problem was with the 3.2.2 release. Went back to the DB Query Monitor Plugin 3.1.0 release and it worked. Thanks.

  22. Anonymous (login to see details)

    Hi,

    We have deployed the DB Monitoring plugin with the Windows server, and tried to get the results in monitor dashboard. But still we are not getting the results in it.  We have done few validation to check the results as well.

    1. Try to use the Generic SQL query whereas provide the wide range of results.

      e.g., Select * from dba_tablespaces;

    2. Updated the plugin version to latest and also changed the destination server which the query needs to run.

    Verified the same query in the DB sql server which returned 30+ results.

    Measures in the Monitor Dashboard Showing Null

    Whereas we are tried the simple query without any conditional statements. Still the results will be shown as zero. We have followed all the steps stated in this page. Attached the logs and SS here.

    Please help us to fix this.

    Regards,

    Aravindhan

    1. Anonymous (login to see details)

      Could you please set the logging level to 'FINER', and paste the log for a run?

      1. Anonymous (login to see details)

        Rajesh, 

        We have archived the logs from the server after enabled FINER. But unable to attach here. Could you please guide me how to share the log files with you?

        Regards,

        Aravindhan

  23. Anonymous (login to see details)

    I am connecting to oracle database and running a simple count(*) from query. I see the query executed successfully(db connection=1) and my DB team says the query ran fine, but my column value is reported at 0 even though there are 34 rows in that table. I do have capture column data turned on.Any help is appreciated?

    Log snippet:(Log level set to FINER)

    2015-10-06 15:35:39 INFO [QMonitor@DB connection check_0] Connecting to Oracle database: jdbc:oracle:thin:@(DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = xxxxxx)(PORT = xxxxxx))(CONNECT_DATA = (SERVICE_NAME = xxxxxxx)(SERVER = DEDICATED)))
    2015-10-06 15:35:39 INFO [QMonitor@DB connection check_0] Executing SQL: select count(*) from xxxxxx 

     

  24. Anonymous (login to see details)

    The column value returned must be a numeric value and you have to check mark the capture column data box in the monitoring properties and tell it what the column name is.

  25. Anonymous (login to see details)

    Rajesh,

    We have sent the log files archive to community. Please check and help us to resolve this.

    Regards,

    Aravindhan. V

  26. Anonymous (login to see details)

    The plugin version 3.2.2 is working with dT6.1. Is it compatible with version dT6.2? 

    I assume it is because of this versin desc: DB Query Monitor Plugin 3.2.1 (added support for PostgreSQL - dynatrace >5.5)



  27. Anonymous (login to see details)

    We've been able to get this plugin to work with SQL Server Windows Authentication as well using the following steps:

    1. run the collector on a Windows machine
    2. add "integratedSecurity=true" to the connection string (use the "Edit URL" link to paste the connection string directly). Remove the username and password attributes from the connection string. So it might look something like this: "jdbc:sqlserver://YOURDBHOSTNAME:YOURPORT;databaseName=YOURDBNAME;instance=YOURDBINSTANCE;integratedSecurity=true"
    3. copy "sqljdbc_auth.dll" (correct bitness) to Dynatrace\VERSION\jre\bin on the collector machine
    4. restart the collector

    The plugin will then connect to the database with the user context the Collector service is running in.

    We've been using AppMon & UEM v 6.2

  28. Anonymous (login to see details)

    When I tried to Setup a DB Query monitor for MS SQL server , It shows zero values in Column values Dynatrace version 6.1 DB Query monitor 3.2.0, any hints

    1. Anonymous (login to see details)

      having same issue. DT version 6.3 going against MSSQL database. Validated we are seeing the collector hit the MSSQL server...

  29. Anonymous (login to see details)

    I am connecting to an Oracle database, and the log shows the following comment:

    ENTRY Arguments not traced

    RETURN null

    Does anyone know what would cause that message?

  30. Anonymous (login to see details)

    Got db monitor working. Polled for 2 days (once every 5 minutes) and then stopped. Nothing in the log to show why. Restarting collector did not help. Disabling and re-enabling db query plugin did not help. No idea what to do next other than maybe uninstall plugin and reinstall, but I can't do that every 2 days

    1. Anonymous (login to see details)

      Anything in the plugins log file? it creates a log on the collector where it gets executed. can you take a look?

  31. Anonymous (login to see details)

    I am trying to use this plugin for getting the column return value which is string, btw this is returning only numeric value, is there a way if we can get string value 

    any help is appreciated

     


    1. Anonymous (login to see details)

      Every Monitor in Dynatrace returns Numeric Values becuase these values will end up as measure points/values in our performance warehouse for you to chart later on. A String value cant be charted - this is why none of our monitoring plugins can query a string value. 

      What would be your use case? what would you want to do with a string if you cant chart it?

  32. Anonymous (login to see details)

    Hi Andy

    Here the customer has a table which records functional errors and they have grouped them in respective categories, the categories are in the form of string in a given column , now they would like to query using this plugin and split them with categories value and chart their respective count  

    Regards

    Ibrahim

    1. Anonymous (login to see details)

      Ibrahim,

       

      I originally wrote this plugin.  I talked to Andi and I will look into adding this splitting ability some time next week.

       

      Thanks,

      Brian

      1. Anonymous (login to see details)

        Hi Brian,
        As mentioned by Ibrahim, would be great to have the functionality of store one string column as Dynamic Measure Name. Are you working on this change?
        Thanks!
        Luis Redda

  33. Anonymous (login to see details)

    Hi, how are you
    I can't get the Query values.
    DB Connection continues to appear at 0, even though it returns time results.

    Column Value: 0.0
    Column Value (Prueba,Pagos): 0.0
    Connect Response Time: 12.484701
    Content Verified: 0.0
    DB Connection: 0.0
    Query Response Time: 2.5075
    Response Time: 14.992201
    Row Count: 0.0

  34. Anonymous (login to see details)

    Christopher,

    The DB Connection being 0 means that you are not actually able to execute your query on the database.  There should be a db plugin log file on the collector you are executing the monitor on.  This log file should give you information as to why the connection is not working.

    -Regards,

    Brian

  35. Anonymous (login to see details)

    Hello,

    I was wondering if the SQL Statement field takes only one statement or can be configured for multiple statements to be run on the same data base and port.

     

    Thank you,

    Krystal

  36. Anonymous (login to see details)

    Hello,

    I am having a strange issue with the DB Query Monitor.  I have 3 monitors configured.  All pointing to the same DB server.  Two of them are pointing to the same DB, and the third is pointing to a different DB.  The two that are using the same DB are executing successfully, but the third is getting DB Connection = 0.  I tested running the Select Query thru Management Studio using the same Windows login credentials and it works successfully.  In the Log file, I see a login failure error.  Very confused on why this one won't work, but the other two do.  Below is the error (Also, thanks for any help) :

     

    017-04-06 09:52:40 SEVERE [QMonitor@Outbound EDI data queue_0] com.microsoft.sqlserver.jdbc.SQLServerException: Cannot open database "wmtn96" requested by the login. The login failed. ClientConnectionId:4280afff-4f2f-4bcf-bd0d-f450bd6a2d81
    at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:216)
    at com.microsoft.sqlserver.jdbc.TDSTokenHandler.onEOF(tdsparser.java:254)
    at com.microsoft.sqlserver.jdbc.TDSParser.parse(tdsparser.java:84)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection$1LogonProcessor.complete(SQLServerConnection.java:2665)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.sendLogon(SQLServerConnection.java:2910)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.logon(SQLServerConnection.java:2234)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.access$000(SQLServerConnection.java:41)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection$LogonCommand.doExecute(SQLServerConnection.java:2220)
    at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:5696)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:1715)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:1326)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.login(SQLServerConnection.java:991)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:827)
    at com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:1012)
    at java.sql.DriverManager.getConnection(DriverManager.java:664)
    at java.sql.DriverManager.getConnection(DriverManager.java:270)
    at com.db.monitor.QueryMonitor.execute(QueryMonitor.java:133)
    at com.db.monitor.QMonitor.execute(QMonitor.java:30)
    at com.dynatrace.diagnostics.sdk.UserPluginManager.a(SourceFile:713)
    at com.dynatrace.diagnostics.sdk.UserPluginManager.b(SourceFile:476)
    at com.dynatrace.diagnostics.sdk.UserPluginManager.executePlugin(SourceFile:274)
    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:50)
    at com.dynatrace.diagnostics.sdk.MonitorPluginExecutor.execute(SourceFile:26)
    at com.dynatrace.diagnostics.schedule.ServerJobCenterRegistry.a(SourceFile:190)
    at com.dynatrace.diagnostics.schedule.ServerJobCenterRegistry.a(SourceFile:413)
    at com.dynatrace.diagnostics.schedule.ServerJobCenterRegistry.execute(SourceFile:337)
    at com.dynatrace.diagnostics.schedule.SchedulerJob.a(SourceFile:101)
    at com.dynatrace.diagnostics.schedule.SchedulerJob.work(SourceFile:92)
    at com.dynatrace.diagnostics.schedule.SchedulerJob.executeJobInfo(SourceFile:241)
    at com.dynatrace.diagnostics.schedule.QuartzJob.execute(SourceFile:45)
    at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
    at com.dynatrace.diagnostics.schedule.QuartzThreadPool$WorkerThread.run(SourceFile:788)

     

    Thanks,

    Tom

  37. Anonymous (login to see details)

    Hallo,

    I am trying to capture some data which is a string, but I have converted it with DECODE and TO_NUMBER to a number.

    It looks like this:

    select TO_NUMBER(DECODE(system_state,'NOT_OPEN','0','AVAILABLE','1')) as gate_open from system_state where...

    In the DB monitor I set up "gate_open" as the column value that I want to capture.H owever the DB monitor always displays 0 and also returns a row count of 0 which indicates that the query is empty.

    Since count(*) is also a pseudo-column that does work, I do not really understand why it doesn't work with my own column.

    Does anybody have a hint?

    1. Anonymous (login to see details)

      Joerg,

       

      This sounds like there is an error in the plugin with either executing your query or parsing the query.  Have you checked the com.db.tabmon.monitor.0.0.log log file on the collector for errors?

       

      Thanks,

      Brian

      1. Anonymous (login to see details)

        Brian,

        thanks for your reply.

        Unfortunately I cannot connect to the server, I just have access to the DT client. I have checked the query in the SQL developer tool first and it works fine there.

        1. Anonymous (login to see details)

          Joerg,

           

          You can access Collector logs from the Dynatrace Client by opening the System Information dashboard from under Status Overview in the cockpit.  From there you can expand the server, and then connected systems and locate the collector from the list.

           

          Thanks,

          Brian

          1. Anonymous (login to see details)

            Hi Brian,

            thank you VERY MUCH. That was great help, I didn't know I could find the logfiles there.

            The mistake was the ending semicolon in the SQL statetment which I copied directly from the SQL developer. It must not be there in the SQL statement field in the DB Monitor plugin.

             

            Thanks a lot.

            Joerg

  38. Anonymous (login to see details)

    Joerg,

     

    Glad to hear that everything has worked out!

     

    Regards,

    Brian

  39. Anonymous (login to see details)

    Hello, we need a little help pls.. 
    Our customer used db monitor plugin to run once a day SQL query for getting results from db.

    Result Values are then shown in Dashboard for trending purpose monthly/quarter year...
    Last week they changed host  in the monitor (and url - connection string accordingly)   - removed old one and added the new one.
    They used the same Monitor (didnt create a new One - just edited it.)

    Since then, all historical data has been lost, Dashboard  is only showing data from the change.

    They are asking us for the data, but we're not able to get it.
    We know they must be in the PWH db...
    We tried to change host and url back to what was there originaly but it didnt help..

    Is there any way, procedure how to get  the lost data ? 

    Thanks,

    Regards

    Ivo