Submit a ticketCall us

Systems Monitoring for Dummies
Our new eBook will teach you the fundamentals and help you create monitors and alerts that are effective, meaningful, and actionable. Monitoring is more than a checkbox on your to-do list. This free eBook will give you practical advice to help you succeed in all aspects of monitoring – discovery, alerting, remediation, and troubleshooting. Don’t miss out on this indispensable resource for newbies, experienced IT pros, and everyone in between. Register Now.

Home > Success Center > Database Performance Analyzer (DPA) > Sybase DYNAMIC_SQL (No SQL text reported by database)

Sybase DYNAMIC_SQL (No SQL text reported by database)

Updated March 14, 2017

Overview

SQL texts are missing for some items in Sybase ASE 15.7.

Environment

  • Sybase ASE 15.7
  • All DPA versions 

Cause 

This behavior is normally seen with Java and jTDS when specific options are used and the same session executes more than one query, one of which is a prepared statement. The options are: jTDS property: "prepareSQL=1" session property: "SET QUOTED_IDENTIFIER OFF"

It has to do with how jTDS is using Sybase's prepared SQL and it seems to occur when you use the same session to run the the same query multiple times 
(ie. they are probably using a connection pool). It is an optimization that occurs.

Resolution

Request the Java developers to change the jTDS connection.
URL to specify prepareSQL=2 or prepareSQL=3 rather than the default of 1. 

You can find more information about jTDS and prepareSQL here:

JTDS (http://jtds.sourceforge.net/faq.html)

prepareSQL (default - 3 for SQL Server, 1 for Sybase)
This parameter specifies the mechanism used for Prepared Statements.
    Value Description
    0 SQL is sent to the server each time without any preparation, literals are inserted in the SQL (slower)
    1 Temporary stored procedures are created for each unique SQL statement and parameter combination (faster)
    2 sp_executesql is used (fast)
    3 sp_prepare and sp_cursorprepare are used in conjunction with sp_execute and sp_cursorexecute (faster, SQL Server only)

 

Disclaimer: Please note, any content posted herein is provided as a suggestion or recommendation to you for your internal use. This is not part of the SolarWinds software or documentation that you purchased from SolarWinds, and the information set forth herein may come from third parties. Your organization should internally review and assess to what extent, if any, such custom scripts or recommendations will be incorporated into your environment.  You elect to use third party content at your own risk, and you will be solely responsible for the incorporation of the same, if any.

 

 

Last modified

Tags

Classifications

Public