title: Create Sql Server view using table name from sysobjects table
body: <p>I have around 200 tables. I want to create a <code>view</code> from all these tables. I feel it is inefficient to hardcode all the table names and do an <code>UNION ALL</code> in the view definition.</p>
  
  <p>Instead I am planning to retrieve the table name from <code>sysobjects</code> table like</p>
  
  <pre><code> Select name from sysobjects where name like 'Warehouse_Inventory%'
  </code></pre>
  
  <p>How can I use these table names and create a <code>view</code> out of it?</p>
  
  <p>Note: I am selecting only 10 columns which are common. If any column is not present in a table, I want to display NULL for it.</p>