bulk actions with large dataset
when doing bulk action on 100k records, the app is freezed
the action is attach many to many relation to selected records
any idea how to solve it ?
Thx in advance
5 Replies
Are you sure it is frozen, and not just thinking?
You could load the records into an unrelated staging table, then go through in batches to do the more complicated attach process.
That way you could have a progress bar or some other visual clue it is still processing.
That's a good idea, how to implement such thing?
No it freeze, i read it may be caused by the memory
@Matthew it just show this
https://prnt.sc/rvDN8zk1H_5P
how many records can you import without it breaking?
Maybe easier to limit to that.
To implement a staging table, you'll have to create a new model to import the records, then use a renderhook to call a handler to deal with the information sitting there.
Dependent on your use case, it will probably be easier to limit the import numbers.
If you are regularly grabbing 100k in records and importing them, it feels like a different solution is required.
it's not an import, let's say it's bulk attaching (many-to-many) action