On Tue, 27 Aug 2019 at 21:57, Peng Yu <pengyu...@gmail.com> wrote:

> I haven't found an archive format that allows in-place delete (I know
> that .zip, .7z and .tar don't). This means that whenever delete is
> needed, the original archive must be copied first. This can be
> problematic when the archive is large and the file to delete is small.
>
> Something along the line of the ability of sqlite3 to perform in-place
> delete might be a useful feature for archives. But I haven't found any
> such archive format. Does anybody know one? Thanks.
>

Note that you wouldn't actually reclaim any disk space by deleting a file
in-place from an archive backed by sqlite -- unless you issue a VACUUM,
which rewrites the whole DB. Without a VACUUM, the free pages within the DB
would only be taken advantage of by future additions to the archive.

That may be an acceptable compromise for the
delete-small-file-from-large-archive use case you're presenting, but the
fact that archive formats are generally designed to minimise storage
requirements goes a long way towards explaining why the scenario is not
well-catered for. It also raises the question of whether an archive is the
correct tool for the job!

-Rowan
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to