How to get the current sqlite database size or package size in Android?

Viewed 29566
4 Answers

You can use this raw query as well, on sqlite 3.16.0+:

SELECT page_count * page_size as size FROM pragma_page_count(), pragma_page_size();

It returns the "size" column with the single row.

Related