title: 'tuple' object has no attribute 'encode'
body: <p>The code is the following (I am new to Python/Mysql):</p>
  
  <pre><code>import mysql.connector
  
  conn = mysql.connector.connect(host='localhost',user='user1',password='puser1',db='mm')
  cursor = conn.cursor()
  string1 = 'test1'
  insert_query = """INSERT INTO items_basic_info (item_name) VALUES (%s)""", (string1)
  cursor.execute(insert_query)
  conn.commit()
  </code></pre>
  
  <p>When I run this code I get this error: </p>
  
  <pre><code>Traceback (most recent call last)
  File "test3.py", line 9, in &lt;module&gt;
  cursor.execute(insert_query)
  File "C:\Users\Emanuele-PC\AppData\Local\Programs\Python\Python36\lib\site-packages\mysql\connector\cursor.py", line 492, in execute
  stmt = operation.encode(self._connection.python_charset)
  AttributeError: 'tuple' object has no attribute 'encode'
  </code></pre>
  
  <p>I have seen different answers to this problem but the cases were quite different from mine and I couldn't really understand where I am making mistakes. Can anyone help me?</p>