title: Can I split a single SQL 2008 DB Table into multiple filegroups, based on a discriminator column?
body: <p>I've got a SQL Server 2008 R2 database which has a number of tables. Two of these tables contains a lot of <em>large</em> data  .. mainly because one of them is <code>VARBINARY(MAX)</code> and the sister table is <code>GEOGRAPHY</code>. (Why two tables? Read Below if you're interested***)</p>
  
  <p>The data in these tables are geospatial shapes, such as zipcode boundaries.</p>
  
  <p>Now, the first 70K odd rows are for <code>DataType = 1</code>
  the rest 5mil rows are for <code>DataType = 2</code></p>
  
  <p>Now, is it possible to split the table data into two files? so all rows that are for <code>DataType != 2</code> goes into <code>File_A</code> and <code>DataType = 2</code> goes into <code>File_B</code>?</p>
  
  <p>This way, when I backup the DB, I can skip adding File_B so my download is waaaaay smaller? Is this possible?</p>
  
  <hr>
  
  <p>I guessing you might be thinking -> why not keep them as TWO extra tables? Mainly because in the code, the data is conceptually the same .. it's just happens that I want to split the storage of this model data. It really messes up my model if I now how two aggregates in my model, instead of one.</p>
  
  <p>***Entity Framework doesn't like Tables with <code>GEOGRAPHY</code>, so i have to create a new table which transforms the <code>GEOGRAPHY</code> to <code>VARBINARY</code>, and then drop that into EF.</p>