Skip to content
This repository has been archived by the owner on Jan 3, 2022. It is now read-only.

Data Types

tsutomi edited this page Sep 29, 2014 · 3 revisions

DeveelDB implements support for most of the SQL data types, but internally they are mapped to few specific system types for handling values. Anyway, the SQL types are recognized in queries and in some cases are important to define the dynamics of the system types. An easy example is the SQL type TIMESTAMP, that is mapped to the DeveelDB type Date, which also handles SQL types DATE and TIME, but differently from the others in the same category, holds a wider range of values.

SQL Types Managed

Boolean Types

  • BIT, BOOLEAN - The most elementary type, that holds a single bit that can be either 0 or 1. It supports assigned values from false and true and can be converted to a NUMERIC value.

Numeric Types

The system handles all the numeric types using the type NUMERIC, which supports big numbers, over the range of values handled by maximum wide of ranges of integers and floating numbers. Anyway, in some situations (eg. some arithmetic functions), the value is cast to a lower precision to be computed.

  • TINYINT
  • SMALLINT
  • INT, INTEGER
  • BIGINT
  • FLOAT, REAL
  • DOUBLE
  • NUMERIC

Date/Time Types and Intervals

  • DATE
  • TIME
  • TIMESTAMP
  • DAY TO YEAR
  • HOUR TO SECOND
  • INTERVAL

String Types

  • CHAR
  • VARCHAR
  • LONGVARCHAR
  • STRING, CLOB

Binary Types

  • BINARY
  • VARBINARY
  • LONGVARBINARY
  • BLOB