mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-07 07:02:54 +00:00
perf: use unbuffered_cursor for stock_ageing report (#39399)
perf: use unbuffered_cursor for stock stock_ageing report Unbuffered cursor lets us load one row at a time in memory from mysql instead of lowing all at once. This makes it possible to run the report for large number of SLEs.
This commit is contained in:
@@ -233,6 +233,8 @@ class FIFOSlots:
|
||||
"""
|
||||
|
||||
stock_ledger_entries = self.sle
|
||||
|
||||
with frappe.db.unbuffered_cursor():
|
||||
if stock_ledger_entries is None:
|
||||
stock_ledger_entries = self.__get_stock_ledger_entries()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user