title: linq to sql using select new inside class file
body: <p>I usually use linq to sql with an <strong><em>IQueryable</em></strong> or <strong><em>IEnumerable</em></strong> to get data like this:</p>
  
  <pre><code>    public static IQueryable getSomething() 
      {
          var getit = from d in database.table select d;
  
          return getit;
      }
  </code></pre>
  
  <p>and it works fine but i am trying to use select new with it like this:</p>
  
  <pre><code>    public static IQueryable getSomething() 
      {
         var getit = from d in database.table select new 
         { 
            value1 = d.1,
            value2 = d.2
         };
  
      return getit;
  }
  </code></pre>
  
  <blockquote>
    <p>this is a sample code and not the actual code.</p>
  </blockquote>
  
  <p>but that wont work, how do i do this?</p>
  
  <p>thanks</p>