MSSQL Ver

Data Type

Firebird

MSSQL definition and comments

6.5

bigint

INT64

8-byte integer type.

6.5

binary

CHAR

Fixed-length binary data with a maximum length of 8,000 bytes. In 6.5, maximum was 255.

6.5

bit

CHAR(1)

Integer data with either a 1 or 0 value. Typically, replaced by constants 'T' and 'F'.

6.5

char

CHAR

Fixed-length non-Unicode character data with a maximum length of 8,000 characters. In 6.5, maximum was 255. Firebird can hold up to 32,767 characters.

6.5

cursor

A reference to a cursor. This can only be used inside stored procedure or triggers; it cannot be used on table declarations.

6.5

datetime

TIMESTAMP

Date and time data from January 1, 1753, to December 31, 9999, with an accuracy of three-hundredths of a second, or 3.33 milliseconds.

6.5

decimal

DECIMAL

Fixed precision and scale numeric data from -1038 -1 through 1038 -1.

6.5

float

FLOAT

Floating precision number data from -1.79E + 308 through 1.79E + 308.

6.5

image

BLOB

Variable-length binary data with a maximum length of 231 - 1 (2,147,483,647) bytes.

6.5

int

INTEGER

Integer (whole number) data from -231 (-2,147,483,648) through 231 - 1 (2,147,483,647).

6.5

money

DECIMAL(18, 4)

Monetary data values from -263 (-922,337,203,685,477.5808) through 263 - 1 (+922,337,203,685,477.5807), with accuracy to a ten-thousandth of a monetary unit.

7

nchar

CHAR(x) CHARACTER SET UNICODE_FSS

Fixed-length Unicode data with a maximum length of 4,000 characters.

7

ntext

BLOB SUB_TYPE TEXT

Variable-length Unicode data with a maximum length of 230 - 1 (1,073,741,823) characters.

6.5

numeric

NUMERIC

In MS SQL, decimal and numeric are synonims.

7

nvarchar

VARCHAR(x) CHARACTER SET UNICODE_FSS

Fixed-length Unicode data with a maximum length of 4,000 characters.

6.5

real

DOUBLE

Floating precision number data from -3.40E + 38 through 3.40E + 38.

6.5

smalldatetime

TIMESTAMP

Date and time data from January 1, 1900, through June 6, 2079, with an accuracy of one minute. Firebird's has greater range and accuracy.

6.5

smallint

SMALLINT

Integer data from -215 (-32,768) through 215 - 1 (32,767).

6.5

smallmoney

DECIMAL(10, 4)

Monetary data values from -214,748.3648 through +214,748.3647, with accuracy to a ten-thousandth of a monetary unit. Note that Firebird's range is greater with this declaration.

2000

sql_variant

BLOB

Allows the storage of data values of different data types.

2000

table

none

Stores results temporarily for later user.

6.5

text

BLOB SUB_TYPE TEXT

Variable-length non-Unicode data with a maximum length of 231 - 1 (2,147,483,647) characters.

6.5

timestamp

INTEGER

A database-wide unique number. In Firebird, you will have to manage uniqueness through generators.

6.5

tinyint

SMALLINT

Integer data from 0 through 255. Firebird does not have such a small data type.

6.5

varbinary

CHAR

Variable-length binary data with a maximum length of 8,000 bytes.

6.5

varchar

VARCHAR

Variable-length non-Unicode data with a maximum of 8,000 characters. Firebird can hold up to 32,765 characters. In 6.5, maximum was 255.

7

uniqueidentifier

CHAR(38)

A globally unique identifier (GUID). In Firebird, you will have to generate the values with User-Defined Functions (UDFs).

 
 

Mssql Data Type



◆ Integers


bigint : sql2000부터 생긴 데이터 형으로

      -2^63 (-9223372036854775808) 부터

      2^63-1 (9223372036854775807) 까지의 정수를 지정 가능 합니다.

int : -2^31 (-2,147,483,648) 부터

       2^31 - 1 (2,147,483,647)까지의 정수를 지정 가능 합니다.

smallint : 2^15 (-32,768) 부터  2^15 - 1 (32,767)까지의 정수를 지정 가능 합니다.

tinyint : 0 부터 255 까지의 정수를 지정 가능 합니다.



◆ bit


bit : 1 또는 0  이라는 데이터를 저장 가능하며 참, 거짓에 사용 됩니다.



◆ decimal and numeric


decimal : -10^38 -1  10^38 -1 까지의 수에 대해

       정밀도와 크기를 사용자에 의해 지정 가능 합니다.

numeric : decimal 형과 같습니다.



◆ money and smallmoney


money : 돈과 관계되는 데이터 타입으로  -2^63 (-922,337,203,685,477.5808) 부터
       2^63 - 1 (+922,337,203,685,477.5807)까지의 수치를 사용가능 하며
       1000단위 컴마를 사용 가능 합니다.
        천조 까지의 데이터를 처리 가능합니다.

smallmoney : -214,748.3648 부터 +214,748.3647 까지 사용 가능하며
       1000단위 컴마 지정이 가능 합니다.



◆ Approximate Numerics


float : 부동(정확하지 않은) 소수 데이터 형으로
       -1.79E + 308 부터  1.79E + 308 까지의 데이터 사용이 가능 합니다.

real : -3.40E + 38 부터 3.40E + 38 까지의 부동 소수 데이터 형입니다.



◆ datetime and smalldatetime


datetime : 1월  1일, 1753년, 부터 12월 31일, 9999년, 까지의 데이터를
       1000분의 일초 단위로 지정 가능 합니다.

smalldatetime : 1월 1일, 1900년, through 6월 6일, 2079년, 까지
       1분 단위 정확도로 지정 가능 합니다.



◆ Character Strings


char : 8,000바이트(문자)까지 지정 가능한 유니코드가 아닌
       고정길이 데이터 형입니다.

varchar : 8,000바이트 까지 지정 가능한 유니코드가 아닌
       가변길이 데이터 형입니다.

text : 2^31 - 1 (2,147,483,647) 유니코드가 아닌
       가변길이 데이터형으로 2기가 까지 지정 가능 합니다.

+ Recent posts