Skip to content

Commit 24862b0

Browse files
bpo-41724: Explain when the conversion is not possible with detect_types enabled (GH-23855) (GH-23863)
* Explain when the conversion is not possible with detect_types enabled (cherry picked from commit 09a36cd) Co-authored-by: sblondon <sblondon@users.noreply.github.com>
1 parent 80c445c commit 24862b0

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

Doc/library/sqlite3.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,9 @@ Module functions and constants
197197

198198
*detect_types* defaults to 0 (i. e. off, no type detection), you can set it to
199199
any combination of :const:`PARSE_DECLTYPES` and :const:`PARSE_COLNAMES` to turn
200-
type detection on.
200+
type detection on. Due to SQLite behaviour, types can't be detected for generated
201+
fields (for example ``max(data)``), even when *detect_types* parameter is set. In
202+
such case, the returned type is :class:`str`.
201203

202204
By default, *check_same_thread* is :const:`True` and only the creating thread may
203205
use the connection. If set :const:`False`, the returned connection may be shared

0 commit comments

Comments
 (0)