title: questions about btree and index to database
body: <p>I read tons of articles about btree theorem about database..thing there is always bewildering.<br>
  assuming I have a table as described as follow:<br>
  table userinfo:<br>
  <strong>(user_id as primary key, username as string, password as string)</strong><br>
  as described in some articles, the user_id is created as <strong>index</strong> for the table <strong>userinfo</strong>, I will get efficient preformance, if i <strong>select</strong> records by index of user_id..
  but if i <strong>select</strong> by <strong>username</strong>, it's said it campares the lines one by one.....
  I try this in <em><strong>MYSQL</strong></em> , it is not as slow as expected....<br>
  why?<br>
  how does <strong>mysql</strong> do with this selcetion??
  thanx</p>