I was trying to use the import wizard of SQL Server 2008 to import data I have exported from another SQL Server database saved to a text file. The wizard tried to import the data as varchar, and when I went to change the data type to int I couldn’t find an int data type. There were a couple of int options (4/8 bit (un)signed int). Which is the SQL int type?
Thanks
The “standard” SQL Server
intis4 bytes, signed. See here for more info.So, in T-SQL, if you do something like:
then
@iwill be a signed, four-byte integer with possible ranges of -2^31 (-2,147,483,648) to 2^31-1 (2,147,483,647).