Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8452613
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T11:32:45+00:00 2026-06-10T11:32:45+00:00

I have Python code: cursor.execute(‘INSERT INTO users (email, password, password_hint, state, last_saved) VALUES (?,

  • 0

I have Python code:

cursor.execute('INSERT INTO users (email, password, password_hint, state, last_saved) VALUES (?, ?, ?, ?, DATETIME("now"));',
((get_cgi('email'),), (password,), (get_cgi('password_hint'),), (get_cgi('current'),)))

This is generating the following error:

Traceback (most recent call last):
  File "./create_account.cgi", line 73, in <module>
    ((get_cgi('email'),), (password,), (get_cgi('password_hint'),), (get_cgi('current'),)))
sqlite3.InterfaceError: Error binding parameter 0 - probably unsupported type.

A debug log of get_cgi(’email’) placed just before the crash returns the expected email address, so I would expect that the column ’email’ of type TEXT should be able to deal with it.

What is SQLite3 complaining about? Have I missed some detail of DB-API2?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T11:32:47+00:00Added an answer on June 10, 2026 at 11:32 am

    I’m not sure why you’re creating all those nested tuples, but removing them should make things work better; a tuple is not supported to insert (at least in this way) into a text field.

    cursor.execute(
        'INSERT INTO users (email, password, password_hint, state, last_saved) ' +
        'VALUES (?, ?, ?, ?, DATETIME("now"));',
        (get_cgi('email'), password, get_cgi('password_hint'), get_cgi('current')))
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following Python code: cursor.execute("INSERT INTO table VALUES var1, var2, var3,") where
I have the following python code which pushes data to db: cursor.execute(INSERT INTO +
I'm using this code in Python: for ... : cursor.execute('INSERT OR IGNORE INTO foo
I have some python code that I wrote to convert a python list into
I'm trying to insert new records into SQLite database from Python code. con =
I have a problem using the MySQLdb library. I'm trying to insert values into
I have installed python 2.7 64bit,MySQL-python-1.2.3.win-amd64-py2.7.exe. I use the following code to insert data
I have this code in Python: conn = sqlite3.connect(people.db) cursor = conn.cursor() sql =
Hi I have this basic mysql code: sql = 'INSERT INTO popularity (PersonNumber, Category,
I have some python code using shutil.copyfile: import os import shutil src='C:\Documents and Settings\user\Desktop\FilesPy'

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.