We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c915543 commit a769b8eCopy full SHA for a769b8e
bench.py
@@ -117,6 +117,14 @@ def select_prefetch(i):
117
for i in c.items:
118
pass
119
120
+@timed
121
+def select_prefetch_join(i):
122
+ query = prefetch(Collection.select(), Item,
123
+ prefetch_type=PREFETCH_TYPE.JOIN)
124
+ for c in query:
125
+ for i in c.items:
126
+ pass
127
+
128
129
if __name__ == '__main__':
130
db.create_tables([Register, Collection, Item])
@@ -138,4 +146,5 @@ def select_prefetch(i):
138
146
select_related_dicts()
139
147
select_related_dbapi_raw()
140
148
select_prefetch()
149
+ select_prefetch_join()
141
150
db.drop_tables([Register, Collection, Item])
0 commit comments