diff options
author | Xtreak <tir.karthi@gmail.com> | 2019-05-19 21:52:20 (GMT) |
---|---|---|
committer | Berker Peksag <berker.peksag@gmail.com> | 2019-05-19 21:52:20 (GMT) |
commit | 287b84de939db47aa8c6f30734ceb8aba9d1db29 (patch) | |
tree | 0c492acbe1135b59f30a0dc8aa5bfd0705387371 /Doc/includes/sqlite3/execute_3.py | |
parent | 5c08ce9bf712acbb3f05a3a57baf51fcb534cdf0 (diff) | |
download | cpython-287b84de939db47aa8c6f30734ceb8aba9d1db29.zip cpython-287b84de939db47aa8c6f30734ceb8aba9d1db29.tar.gz cpython-287b84de939db47aa8c6f30734ceb8aba9d1db29.tar.bz2 |
bpo-34580: Update sqlite3 examples to call close() explicitly (GH-9079)
The sqlit3.Connection object doesn't call its close() method when it's used
as a context manager.
Diffstat (limited to 'Doc/includes/sqlite3/execute_3.py')
-rw-r--r-- | Doc/includes/sqlite3/execute_3.py | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/Doc/includes/sqlite3/execute_3.py b/Doc/includes/sqlite3/execute_3.py deleted file mode 100644 index 0353683..0000000 --- a/Doc/includes/sqlite3/execute_3.py +++ /dev/null @@ -1,12 +0,0 @@ -import sqlite3 - -con = sqlite3.connect("mydb") - -cur = con.cursor() - -who = "Yeltsin" -age = 72 - -cur.execute("select name_last, age from people where name_last=:who and age=:age", - locals()) -print(cur.fetchone()) |