Promotic
WikipediaLinkedInYoutubeTwitterFacebook

Data type in Firebird

Data type Length Description
SMALLINT 2 bytes Range from -32 768 to 32 767 (unsigned: from 0 to 65 535)
INTEGER 4 bytes Range from -2 147 483 648 to +2 147 483 647 (unsigned: from 0 to 4 294 967 295)
BIGINT 8 bytes Range from -9 223 372 036 854 775 808 to +9 223 372 036 854 775 807 (unsigned: from 0 to 18 446 744 073 709 551 615)
DECIMAL(precision,scale)   Range 1-9 INTEGER (32b), 10-18 BIGINT (64b)
NUMERIC(precision,scale)   Range 1-4 SMALLINT (16b, 5-9 INTEGER (32b), 10-18 BIGINT (64b)
FLOAT   Range from 1.175 * 10^-38 to 3.402 * 10^38
DOUBLE PRECISION   Range from 2.225 * 10^-308 to 1.797 * 10^308
DATE '0000-00-00' from 1.1.0001 to 31.12.9999
TIME '00:00:00' from 0:00:00:0000 to 23:59:59:9999
TIMESTAMP(n) '0000-00-00 00:00:00' from 1.1.0001 0:00:00:0000 to 31.12.9999 23:59:59:9999
CHAR(n),CHARACTER(n)   a string of fixed lenght, where n is the number of stored characters.
VARCHAR(n), CHARACTER VARYING(n)   strings of flexible lenght, where n is the maximum number of characters in the string.
BLOB   large data of flexible lenght, binary data or very large texts
 
precision – (Range) represents the comlete or maximum number of valid digits, also decimal, that can be stored in the column of such type. The range is from 1 to 18 digits.
scale – (Accuracy) repreents the number of decimal digits. The accuracy is defined from 0 to defined range (the accuracy must be less or equal to range).
 
See firebirdsql.org/manual/migration-mssql-data-types.html.
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice