Search This Blog

Tuesday, June 18, 2013

SQL Server and Oracle datatypes Comparison



The following summarizes the datatype of SQL Server and Oracle :
SQL ServerOracle
Exact Numerics
TINYINT
NUMBER(3)
SMALLINT
NUMBER(5)
INTEGER
NUMBER(10)
BIGINT
NUMBER(19)
DECIMAL(p,s)
NUMBER(p,s)
NUMERIC(p,s)
NUMBER(p,s)
SMALLMONEY
NUMBER(10,4)
MONEY
NUMBER(19,4)
Approximate Numerics
REAL
BINARY_FLOAT
FLOAT
BINARY_DOUBLE
Date Time
SMALLDATETIME
TIMESTAMP(3)
DATETIME
TIMESTAMP(3)
DATETIME2(fs)
TIMESTAMP(fs)
DATETIMEOFFSET(fs)
TIMESTAMP (fs) WITH TIME ZONE
DATETIMEOFFSET(fs)
TIMESTAMP (fs) WITH LOCAL TIME ZONE
Character strings
CHAR(x)
CHAR(x)
VARCHAR(x)
ARCHAR2(x)
VARCHAR(MAX)
CLOB
TEXT
LONG
Binary strings
BINARY(n)
RAW(n)
VARBINARY(n)
LONG RAW
VARBINARY(MAX)
LONG RAW or BLOB
IMAGE
LONG RAW
Binary strings
XML
XMLTYPE
BIT
NUMBER(1)
TIMESTAMP
ORA_ROWSCN pseudo column
UNIQUEIDENTIFIER
RAW(16)
N/A
BFILE

No comments:

Post a Comment