# JDBC escape syntax

JDBC provides a way of smoothing out some of the differences in the way different DBMS vendors implement SQL. This is called escape syntax. Escape syntax signals that the JDBC driver, which is provided by a particular vendor, scans for any escape syntax and converts it into the code that the particular database understands. This makes escape syntax DBMS-independent.

A JDBC escape clause begins and ends with curly braces. A keyword always follows the opening curly brace:

    {keyword }

Derby supports the following JDBC escape keywords, which are case-insensitive:

- JDBC escape keyword for call statements

  The escape keyword for use in CallableStatements.

- JDBC escape syntax

  The escape keyword for date formats.

- JDBC escape syntax for LIKE clauses

  The keyword for specifying escape characters for LIKE clauses.

- JDBC escape syntax for fn keyword

  The escape keyword for scalar functions.

- JDBC escape syntax for outer joins

  The escape keyword for outer joins.

- JDBC escape syntax for time formats

  The escape keyword for time formats.

- JDBC escape syntax for timestamp formats

  The escape keyword for timestamp formats.

Other JDBC escape keywords are not supported.
Note: Derby returns the SQL unchanged in the Connection.nativeSQL call, since the escape syntax is native to SQL. In addition, it is unnecessary to call Statement.setEscapeProcessing for this reason.

- JDBC escape keyword for call statements
- JDBC escape syntax
- JDBC escape syntax for LIKE clauses
- JDBC escape syntax for fn keyword
- JDBC escape syntax for outer joins
- JDBC escape syntax for time formats
- JDBC escape syntax for date formats
- JDBC escape syntax for timestamp formats

Parent topic: JDBC Reference
Related concepts
Core JDBC java.sql Classes, Interfaces, and Methods
Related reference
java.sql.Driver
java.sql.DriverManager.getConnection
java.sql.Driver.getPropertyInfo
java.sql.Connection
java.sql.DatabaseMetaData
java.sql.Statement
java.sql.CallableStatement
java.sql.SQLException
java.sql.PreparedStatement
java.sql.ResultSet
java.sql.ResultSetMetaData
java.sql.SQLWarning
java.sql.SQLXML
Mapping of java.sql.Types to SQL types
java.sql.Blob and java.sql.Clob
java.sql.Connection
java.sql.ResultSet
java.sql.Statement
java.sql.PreparedStatement
java.sql.CallableStatement
java.sql.DatabaseMetaData
java.sql.ResultSetMetaData
java.sql.BatchUpdateException
JDBC Package for Connected Device Configuration/Foundation Profile (JSR169)
JDBC 3.0-only features
JDBC 4.0-only features