Ok, lets say i'm using one table in my database called hits and it's an INT(11), and everytime someone visits a page it adds a 1 to that entry... how far up can a INT(11) value go?
Also what's BIG_INT ??
Question about INT
Moderator: General Moderators
- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
http://dev.mysql.com/doc/refman/4.1/en/ ... types.html
The 11 is how many characters it can use. Unsigned maximum on an INT type is 10, while unsigned is 11. Why? The negative sign.
The 11 is how many characters it can use. Unsigned maximum on an INT type is 10, while unsigned is 11. Why? The negative sign.
Thanks for the link.feyd wrote:http://dev.mysql.com/doc/refman/4.1/en/ ... types.html
The 11 is how many characters it can use. Unsigned maximum on an INT type is 10, while unsigned is 11. Why? The negative sign.
Why? Well I'm having a wonderful idea for something, that might take off and just needed to know how far an INT would go upto 'hit' wise. Thank you anyways.
"The negative sign" ?? What neg sign?
- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
Signed integers can be negative. Unsigned cannot. If the number you are dealing with cannot be negative, set the column unsigned to effectively double your available number range. UNSIGNED INT(10) has a range of zero to 4,294,967,295. INT(11) has a range of -2,147,483,648 to 2,147,483,647. It's technically the same number of combinations, just one can do negatives.