Skip to content

IS [NOT] DISTINCT FROM does raise an error with CLOB columns in Oracle #19490

@kaini

Description

@kaini

Expected behavior

No response

Actual behavior

No response

Steps to reproduce the problem

See the following example:

CREATE TABLE mcve.test (
  id NUMBER(7) GENERATED ALWAYS AS IDENTITY NOT NULL,
  cd CLOB,
  
  CONSTRAINT pk_test PRIMARY KEY (id) 
);

INSERT INTO mcve.test (cd) VALUES (null);
INSERT INTO mcve.test (cd) VALUES ('XXXXXXX');
ctx.selectFrom(TEST).where(TEST.CD.isDistinctFrom("XXXXXXX")).fetch();

The result is ORA-00932: expression is of data type CLOB, which is incompatible with expected data type -, because DECODE does not allow CLOBs as first parameter. I assume that the issue is related to #7997.

jOOQ Version

jOOQ Professional Edition 3.20.9

Database product and version

Oracle 19c 19.29.0.0 / Oracle 21c 21.20.0.0 / Oracle 26ai 23.26.0.0

Java Version

java version "21.0.6" 2025-01-21 LTS

JDBC / R2DBC driver name and version (include name if unofficial driver)

ojdbc 23.26.0.0.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions