title: Need to know the working of this code which uses AsEnumerable
body: <p>When I run this code:</p>
  
  <pre><code>return dbAccess.ExecuteDataTable(dbAccess)
                 .AsEnumerable()
                 .Select(r =&gt; r.Field&lt;int&gt;("Id"))
                 .ToList();                       
  </code></pre>
  
  <p>It gives me an error:</p>
  
  <blockquote>
    <p>SqlParameter is already in the SqlParameterCollection</p>
  </blockquote>
  
  <p>Although I know that AsEnumerable works on this concept deferred execution or lazy loading, but this concept still hasnt made a place in my head.</p>
  
  <p>Can anyone please explain the working of AsEnumerable and this code?</p>