title: SQL Server Procedure or function CreateTable has too many arguments specified
body: <p>I want to create a table with 2 columns: Name of the customer of type varchar and age of type int.</p>
  <p>My code:</p>
  <pre><code>CREATE PROCEDURE CreateTable 
      (@tablename varchar(50), 
       @column varchar(50),
       @type varchar(50),
       @column2 varchar(20), 
       @type2 int, 
       @extra varchar(20) = NULL)
  AS
  BEGIN
      DECLARE @sqlQuery AS varchar(MAX)
      SET @sqlQuery = 'CREATE TABLE ' + @tablename +  '( id int '+ @column +' ' + @type + @column2 +' ' + @type2+'  PRIMARY KEY(id))'
  
      PRINT (@sqlQuery)
      EXEC (@sqlQuery)
  END
  GO
  
  EXEC CreateTable 'Customers', 'Name', 'varchar(50)', 'Age', 'int'
  </code></pre>
  <p>The error is:</p>
  <blockquote>
  <p>Procedure or function CreateTable has too many arguments specified</p>
  </blockquote>
  <p>I don't know where my error is. Please help me.</p>