Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #64577
| Date | 2014-01-23 08:37 +0100 |
|---|---|
| From | lgabiot <laurent.gabiot@gmail.com> |
| Newsgroups | comp.lang.python |
| Subject | Re: sqlite3 docbug (was problem with sqlite3) |
| References | (1 earlier) <mailman.5864.1390446316.18130.python-list@python.org> <d8243c7c-8d9c-4ef6-8842-2fe856633a4e@googlegroups.com> <mailman.5870.1390452106.18130.python-list@python.org> <1f13ee0c-5cb5-4627-9f38-2058a8235083@googlegroups.com> <mailman.5872.1390455723.18130.python-list@python.org> |
| Message-ID | <mailman.5873.1390462651.18130.python-list@python.org> (permalink) |
Thanks to all,
that was indeed the tuple issue!
the correct code is:
>>>cursor = conn.execute("SELECT filename, filepath FROM files WHERE
max_level<?", (threshold,))
as was pointed out by many.
Sorry for missing such a silly point (well, a comma in fact). I'll learn
to read more seriously the doc, but I was really confused (I spent more
than one hour trying so many combinations, reading the doc, books I
have, etc... before posting, and I was stuck)
but the basis for my blindness was more a lack of grasp of the
fundamentals: how to declare a one element tuple.
Because I tried to write (threshold) being convinced it was a tuple...
I need to remember at all times: https://wiki.python.org/moin/TupleSyntax
best regards.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
problem with sqlite3: cannot use < in a SQL query with (?) lgabiot <lgabiot@hotmail.com> - 2014-01-23 03:32 +0100
Re: problem with sqlite3: cannot use < in a SQL query with (?) lgabiot <lgabiot@hotmail.com> - 2014-01-23 03:34 +0100
Re: problem with sqlite3: cannot use < in a SQL query with (?) Chris Angelico <rosuav@gmail.com> - 2014-01-23 13:42 +1100
Re: problem with sqlite3: cannot use < in a SQL query with (?) bob gailer <bgailer@gmail.com> - 2014-01-22 21:51 -0500
Re: problem with sqlite3: cannot use < in a SQL query with (?) bob gailer <bgailer@gmail.com> - 2014-01-22 21:51 -0500
Re: problem with sqlite3: cannot use < in a SQL query with (?) Tim Chase <python.list@tim.thechases.com> - 2014-01-22 21:05 -0600
sqlite3 docbug (was problem with sqlite3) Rustom Mody <rustompmody@gmail.com> - 2014-01-22 20:33 -0800
Re: sqlite3 docbug (was problem with sqlite3) Rustom Mody <rustompmody@gmail.com> - 2014-01-22 20:37 -0800
Re: sqlite3 docbug (was problem with sqlite3) Chris Angelico <rosuav@gmail.com> - 2014-01-23 15:41 +1100
Re: sqlite3 docbug (was problem with sqlite3) Rustom Mody <rustompmody@gmail.com> - 2014-01-22 21:35 -0800
Re: sqlite3 docbug (was problem with sqlite3) Chris Angelico <rosuav@gmail.com> - 2014-01-23 16:42 +1100
Re: sqlite3 docbug (was problem with sqlite3) lgabiot <lgabiot@hotmail.com> - 2014-01-23 08:37 +0100
Re: sqlite3 docbug (was problem with sqlite3) Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-01-23 09:04 +0000
Re: sqlite3 docbug (was problem with sqlite3) lgabiot <lgabiot@hotmail.com> - 2014-01-23 10:45 +0100
Re: sqlite3 docbug (was problem with sqlite3) Rustom Mody <rustompmody@gmail.com> - 2014-01-23 02:23 -0800
Re: sqlite3 docbug (was problem with sqlite3) lgabiot <laurent.gabiot@gmail.com> - 2014-01-23 10:45 +0100
Re: sqlite3 docbug (was problem with sqlite3) lgabiot <laurent.gabiot@gmail.com> - 2014-01-23 08:37 +0100
Re: sqlite3 docbug (was problem with sqlite3) Terry Reedy <tjreedy@udel.edu> - 2014-01-23 05:43 -0500
Re: sqlite3 docbug (was problem with sqlite3) Rustom Mody <rustompmody@gmail.com> - 2014-01-23 07:00 -0800
Re: sqlite3 docbug (was problem with sqlite3) Tim Chase <python.list@tim.thechases.com> - 2014-01-23 06:36 -0600
Re: sqlite3 docbug (was problem with sqlite3) Terry Reedy <tjreedy@udel.edu> - 2014-01-23 20:03 -0500
Re: sqlite3 docbug (was problem with sqlite3) Asaf Las <roegltd@gmail.com> - 2014-01-22 23:18 -0800
Re: sqlite3 docbug (was problem with sqlite3) Chris Angelico <rosuav@gmail.com> - 2014-01-23 18:47 +1100
csiph-web