title: How the mysql indexing makes SELECT queries faster
body: <p>hi i know about <code>MySQL</code> Indexes to some extent.</p>
  
  <p>i can create a index when creating a table by</p>
  
  <pre><code>CREATE TABLE Product (
      -&gt;    ID SMALLINT UNSIGNED NOT NULL,
      -&gt;    ModelID SMALLINT UNSIGNED NOT NULL,
      -&gt;    PRIMARY KEY (ID),
      -&gt;    INDEX (ModelID)
  </code></pre>
  
  <p>add an index after create table  by </p>
  
  <pre><code>CREATE INDEX index_name
  ON table_name (column_name)
  </code></pre>
  
  <p>also alter the index by</p>
  
  <pre><code>ALTER TABLE TABLE_NAME ADD INDEX (COLUMN_NAME);
  </code></pre>
  
  <blockquote>
    <p>**what I want to know is how indexing makes the select query fast</p>
  </blockquote>
  
  <p>how does indexing affects to the select algorithm of <code>MySQL</code> , how the indexed columns are affecting to the algorithm ? please explain , thanks in advance </p>