title: sqlite primary key create table error
body: <pre><code>import sqlite3
  
  # set database variables
  sqlite_db_filename = '/samba/anonymous/vacuum_control.sqlite'
  table_name = 'user_recipe'
  new_field_1 = 'recipe_id'
  field_type_1 = 'INTEGER PRIMARY KEY'
  new_field_2 = 'recipe_name'
  field_type_2 = 'TEXT'
  new_field_3 = 'use_vacuum'
  field_type_3 = 'INTEGER'
  
  
  # Connecting to the database file
  conn = sqlite3.connect(sqlite_db_filename)
  c = conn.cursor()
  
  # Creating a new SQLite table with x columns
  
  c.execute('CREATE TABLE {tn} ({nf1} {ft1} {nf2} {ft2})'\
      .format(tn=table_name, nf1=new_field_1, ft1=field_type_1, nf2=new_field_2, ft2=field_type_2))
  
  # Committing changes and closing the connection to the database file
  conn.commit()
  </code></pre>
  
  <h1>QUESTION</h1>
  
  <p>The current code produces the error</p>
  
  <pre><code>"Traceback (most recent call last):
    File "data_base_config.py", line 20, in &lt;module&gt;
      .format(tn=table_name, nf1=new_field_1, ft1=field_type_1, nf2=new_field_2, ft2=field_type_2))
  sqlite3.OperationalError: near "recipe_name": syntax error"
  </code></pre>
  
  <p>If I change <code>field_type_1</code> to just <code>"INTEGER"</code> it works fine. I've looked at many other examples and it seems valid to include <code>INTEGER PRIMARY KEY</code></p>
  
  <p>SQLite version 3.8.7.1 </p>
  
  <p>Thanks</p>