title: Mapping POCO Class to Dynamically Created Tables
body: <p>I have a script running every hour that stores log data in a logging database. Every month a new table is created, and the logging information from this month is stored in that table.</p>
  
  <p>Every table that is created is identical and match a simple POCO class</p>
  
  <pre><code>class IISLog
  {
    SystemRef,
    date,
    s-sitename,
    //etc
   }
  </code></pre>
  
  <p>I've only found a single way to access these tables using a code-first approach:</p>
  
  <pre><code> var result = this.Database.SqlQuery&lt;WebLog&gt;("select * from " + table + "_" + month);
  </code></pre>
  
  <p>However, it appears that I lose the lazy loading in the process since SqlQuery returns an IEnumerable of the type.</p>
  
  <p>Is there any way to let lazy loading prevail as well as allow the data context to track the elements? (Main priority on the first point).</p>