title: T-SQL create table with primary keys
body: <p>Hello I wan to create a new table based on another one and create primary keys as well.</p>
  
  <p>Currently this is how I'm doing it. Table B has no primary keys defined. But I would like to create them in table A. Is there a way using this select top 0 statement to do that? Or do I need to do an ALTER TABLE after I created tableA?</p>
  
  <p>Thanks</p>
  
  <pre><code>select TOP 0 *
  INTO [tableA]
  FROM [tableB]
  </code></pre>