diff options
Diffstat (limited to 'Doc/lib/sqlite3/md5func.py')
-rw-r--r-- | Doc/lib/sqlite3/md5func.py | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/Doc/lib/sqlite3/md5func.py b/Doc/lib/sqlite3/md5func.py deleted file mode 100644 index b7bc05b..0000000 --- a/Doc/lib/sqlite3/md5func.py +++ /dev/null @@ -1,11 +0,0 @@ -import sqlite3 -import hashlib - -def md5sum(t): - return hashlib.md5(t).hexdigest() - -con = sqlite3.connect(":memory:") -con.create_function("md5", 1, md5sum) -cur = con.cursor() -cur.execute("select md5(?)", ("foo",)) -print(cur.fetchone()[0]) |