title: postgresql index on string column
body: <p>Say, I have a table <code>ResidentInfo</code>, and in this table I have unique constraints <code>HomeAddress</code>, which is <code>VARCHAR</code> type. For future query, I gonna add an index on this column.
  The query will only have operation <code>=</code>, and I'll use B-TREE pattern since the Hash pattern is not recommended currently.</p>
  
  <p>Question: From efficiency view, using B-TREE, do you think I should add a new column with numbers 1,2,3....,N corresponding to different homeaddress, and instead of adding index on <code>HomeAddress</code>, I should add index on the number column?</p>
  
  <p>I ask this question because I don't know how index works.</p>