Skip to content

DatabaseMetaData.supportsLikeEscapeClause() Returns true for Synapse Despite the ESCAPE Clause Not Being Supported #2091

@mbach979

Description

@mbach979

Driver version

12.2.0

SQL Server version

Microsoft Azure SQL Data Warehouse - 10.0.15318.0 Jan 1 1601 22:15:43 Copyright (c) Microsoft Corporation

Client Operating System

Windows 10 21H2

JAVA/JVM version

openjdk version "11.0.17" 2022-10-18 LTS
OpenJDK Runtime Environment Corretto-11.0.17.8.1 (build 11.0.17+8-LTS)
OpenJDK 64-Bit Server VM Corretto-11.0.17.8.1 (build 11.0.17+8-LTS, mixed mode)

Problem description

The returned value DatabaseMetaData.supportsLikeEscapeClause() is true when connected to a Synapse instance. Synapse does not support the ESCAPE clause per https://learn.microsoft.com/en-us/sql/t-sql/language-elements/like-transact-sql?view=sql-server-ver16: Currently ESCAPE and STRING_ESCAPE are not supported in Azure Synapse Analytics or Analytics Platform System (PDW).

Expected behavior

The method should return 'false' when connected to a Azure SQL Data Warehouse/Synapse instance.

Actual behavior

Method returns 'true' for all database types.

JDBC Trace Log

synapseMetadataJdbcTrace.log

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in the driver. A high priority item that one can expect to be addressed quickly.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions