Field size of int, bigint, smallint, and tinyint

Poster
Posted by Poster under Sql Server category on | Views : 11759
Here is the field size of SQL server

bigint

Integer (whole number) data from -2^63 (-9,223,372,036,854,775,808) through 2^63-1 (9,223,372,036,854,775,807). Storage size is 8 bytes.

int

Integer (whole number) data from -2^31 (-2,147,483,648) through 2^31 - 1 (2,147,483,647). Storage size is 4 bytes. The SQL-92 synonym for int is integer.

smallint

Integer data from -2^15 (-32,768) through 2^15 - 1 (32,767). Storage size is 2 bytes.

tinyint

Integer data from 0 through 255. Storage size is 1 byte.

For more details, look at http://msdn.microsoft.com/en-us/library/aa933198%28SQL.80%29.aspx

Thanks

Comments or Responses

Login to post response