summaryrefslogtreecommitdiff
path: root/dedup/utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'dedup/utils.py')
-rw-r--r--dedup/utils.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/dedup/utils.py b/dedup/utils.py
new file mode 100644
index 0000000..2fae9fd
--- /dev/null
+++ b/dedup/utils.py
@@ -0,0 +1,7 @@
+def fetchiter(cursor):
+ rows = cursor.fetchmany()
+ while rows:
+ for row in rows:
+ yield row
+ rows = cursor.fetchmany()
+