How to load more than 1 MB of data from sqlite db in android cursor?

I'm definitely trying to load more than 1 MB of data from sqlite database in android cursor. At boot time, it gives the following error, for example

08-04 11:10:15.813: ERROR/CursorWindow(4465): need to grow: mSize = 2097152, size = 403719, freeSpace() = 209669, numRows = 1 08-04 11:10:15.813: ERROR/CursorWindow(4465): Attempting to grow window beyond max size (2097152) 08-04 11:10:15.813: ERROR/Cursor(4465): Failed allocating 403719 bytes for blob at 0,13 08-04 11:10:15.813: DEBUG/Cursor(4465): finish_program_and_get_row_count row 0 08-04 11:10:15.899: ERROR/CursorWindow(4465): need to grow: mSize = 2097152, size = 403719, freeSpace() = 209669, numRows = 1 08-04 11:10:15.899: ERROR/CursorWindow(4465): Attempting to grow window beyond max size (2097152) 08-04 11:10:15.899: ERROR/Cursor(4465): Failed allocating 403719 bytes for blob at 0,13 08-04 11:10:15.899: DEBUG/Cursor(4465): finish_program_and_get_row_count row 0 08-04 11:10:15.899: ERROR/CursorWindow(4465): Bad request for field slot 0,0. numRows = 0, numColumns = 14 08-04 11:10:15.899: DEBUG/AndroidRuntime(4465): Shutting down VM. 

if anyone knows how to load big data (more than 1 MB) into an Android cursor? thanks,

+8
android sqlite android-cursor
source share
1 answer

Do not store 500 KB spots in your database. Save the identifiers in your database and drop the droplets as files into the repository. If you use MODE_PRIVATE, they will not be available to other processes.

+6
source share

All Articles