Skip to content

Change default data type name from DOUBLE to DOUBLE PRECISION #2448

@katzyn

Description

@katzyn
EXPLAIN VALUES CAST(2 AS DOUBLE PRECISION);
> VALUES (CAST(2.0 AS DOUBLE))

In the SQL Standard there is no DOUBLE data type and some databases, including Oracle, PostgreSQL, and SQL Server don't accept it. They all accept DOUBLE PRECISION name from the SQL Standard.

H2 usually preserves names of data types when they're used in table definitions as column data types, but H2 always normalizes them into own default names in all expressions (default and generated columns, check constraints, views, etc.). In result, SCRIPT output contains definitions not compatible with other database systems.

The default name of this data type should be standard-compliant.

@grandinj
Do you agree?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions