The most efficient way to delete old records? #2026
Unanswered
lileishihaoren
asked this question in
Q&A
Replies: 1 comment
-
@lileishihaoren You can run all of your db.BeginTrans();
foreach (var i in intList)
{
col.Delete(i);
}
db.Commit(); This has the (potentially unwanted) side effect that, if a single operation fails, all of the operations are discarded. However, this is the fastest way to run batch operations. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I use the code to delete some old records,is there any more efficient way? Thanks.
in LiteDB V5
Beta Was this translation helpful? Give feedback.
All reactions