| Table Data Type |
Internal Type |
Size Consumed |
Other Notes |
| INT or INTEGER |
DRIZZLE_TYPE_LONG |
4 Bytes
|
Auto Increment Supported.
Optimized for 32 bit Integer. |
| BIGINT |
DRIZZLE_TYPE_LONGLONG |
8 Bytes
|
Auto Increment Supported.
Optimized for 64 bit Integer. |
| DOUBLE or FLOAT |
DRIZZLE_TYPE_DOUBLE |
size of double in the OS
|
Auto Increment Supported |
| DECIMAL or NUMERIC |
DRIZZLE_TYPE_DECIMAL |
?? |
default precision is 10 and maximum precision is 65 |
| VARCHAR |
DRIZZLE_TYPE_VARCHAR |
length of the string + 1, if length < 256
length of the string + 2 otherwise |
?? |
| DATE |
DRIZZLE_TYPE_DATE |
3 bytes |
?? |
| TIMESTAMP |
DRIZZLE_TYPE_TIMESTAMP |
4 bytes |
if TIMESTAMP NOT NULL, then DEFAULT NOW() ON UPDATE NOW() is assumed |
| BLOB or TEXT |
DRIZZLE_TYPE_BLOB |
4 bytes + size of pointer (12 bytes) |
blob cannot have default value |
Data type comparison with Other RDBMS, For Migration
| Drizzle |
MySQL |
SQL Server |
Oracle |
| INT or INTEGER |
INT or INTEGER |
INT |
NUMBER
You need to use number without specifying any precision |
BIGINT
|
BIGINT
|
BIGINT
|
NUMBER
|
DOUBLE or FLOAT
|
DOUBLE or FLOAT
|
SQL Server |
Oracle |
DECIMAL or NUMERIC
|
DECIMAL or NUMERIC
|
SQL Server |
NUMBER(precision,scale)
|
VARCHAR
|
VARCHAR
|
VARCHAR
|
VARCHAR2
|
|
|