title: MS SQL Index column sort order matters?
body: <p>I have a database where I run profiler and database advisor to improve the performance of the database. I did and so far so good, the advisor presented me lots of indexes and statistics that can be created to get better performance.
  But reading the statements I ran into this:</p>
  
  <pre><code>CREATE NONCLUSTERED INDEX [_dta_index_xinfobaseacl_11_397426127__K3_K7_K1_K5] ON [dbo].[xinfobaseacl] 
  (
      [lviewid] ASC,
      [lparentid] ASC,
      [lid] ASC,
      [xlactor] ASC
  )WITH (SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF) ON [PRIMARY]
  go
  
  CREATE NONCLUSTERED INDEX [_dta_index_xinfobaseacl_11_397426127__K7_K5_K1_K3] ON [dbo].[xinfobaseacl] 
  (
      [lparentid] ASC,
      [xlactor] ASC,
      [lid] ASC,
      [lviewid] ASC
  )WITH (SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF) ON [PRIMARY]
  go
  </code></pre>
  
  <p>Same table, same columns, same parameters, just other sort order of the columns...</p>
  
  <p><strong>So I am confused, does the sort order really matters in index creation???</strong></p>