MySQL - Default value in field type INT
<p>I have a question I'd like to help me solve, it's about the values of the data type in the fields of the database.</p>
<ol>
<li>It is mandatory to specify the number of characters or values that will have a field identifier <strong>id INT</strong>.</li>
</ol>
<blockquote>
<p>id INT UNSIGNED NOT NULL AUTO_INCREMENT</p>
</blockquote>
<ol start="2">
<li>What is the difference between <strong>id INT</strong> and <strong>id INT(11)</strong>, It is mandatory to establish a number of values?.</li>
</ol>
<blockquote>
<p>id INT UNSIGNED NOT NULL AUTO_INCREMENT</p>
<p>id(11) INT UNSIGNED NOT NULL AUTO_INCREMENT</p>
</blockquote>
<ol start="3">
<li><p>What is the default setting MySQL in <strong>id INT</strong>, if not specify any value?</p>
</li>
<li><p>What is the maximum amount exact numbers that allows me to add INT</p>
</li>
<li><p>In that case you must use <strong>INT</strong></p>
</li>
<li><p>In that case you should use <strong>BIGINT</strong></p>
</li>
</ol>
<p><strong>Example:</strong> I will take an example of a news portal, that I could receive many visits.</p>
<p>Need to record the number of times it is accessed worldwide news, let's say your news year is visited 999.999.999 times, is a bit exaggerated know :), but it is valid to use in this case <strong>INT</strong> or <strong>BIGINT</strong></p>
<p><em>I much appreciate your support.</em></p>