Integer
A whole number with no fractional part, such as 42 or -7. It is the natural type for counts.
Whole numbers are stored exactly, unlike most fractions, up to the limit of the type's size. Whether a column of digits should be an integer depends on meaning: a quantity yes, a postal code no.
Where it comes up
- Numbers stored as textA column of quantities contains symbols, separators, or words that stop software reading it as numbers.
- Identifiers that lost their leading zerosA code that starts with zero, such as a postal code or account number, was read as a number and the zeros were dropped.
See also
- Floating pointThe usual way computers store numbers with a fractional part, using a fixed number of binary digits. Most decimal fractions cannot be stored exactly, so 0.1 plus 0.2 comes out as 0.30000000000000004.
- Data typeThe kind of value a column holds, such as text, whole number, decimal, date, or true and false. The type decides what operations make sense.
- IdentifierA value whose job is to name one particular thing, such as an account number, a part number, or a postal code. It is a label, even when it is made entirely of digits.