MarcelloDB
MarcelloDB copied to clipboard
is there a way to delete an entire collection without having to iterate all the keys on it?
is there a way to delete an entire collection without having to iterate all the keys on it?
Hi Jose,
If you look at the folder where the data is stored, you will see a file with the exact name as the name you specified when creating the collectionFile. If you have no open sessions, it is save to delete the file, make sure you delete the journal file too. When this file is gone, your collection will be empty.
This will of course delete all collection in the collection file. If you want to delete a single collection without deleting other collection in the same file, there is currently no other way than loading all ids in memory, iterating them and deleting them one by one.
This is also on the roadmap to be implemented.
Thanks Mark I will test this feature when is implemented.