在Android应用程序最大的SQLite数据库大小 [英] Maximum SQLite Database Size in Android Application

查看:706
本文介绍了在Android应用程序最大的SQLite数据库大小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是新来Android的发展。

I am new to the Android Development.

目前,我的工作具有大数据量的一个Android应用程序。

Currently, I am working on one Android Application having a large amount of data.

所以我认为我应该有一些存储这些数据的地方。

So I have thought that I should have to store some of those data locally.

我已经有2个表一个数据库。

I have one database having 2 tables.

表1的大小为:4.5 MB
表2的尺寸为:目前3.5 MB

Table-1's size is: 4.5 MB Table-2's size is: 3.5 MB currently.

即。完全围绕8.0 MB的但在未来的数据库大小可以增加,并且可以达到10兆

i.e. Totally around 8.0 MB but in future database size can be increased and may be reach to 10 MB.

表1:行(14927)和列(17)
表2:行(9903)和列(38)

Table-1: Rows(14927) and Columns(17) Table-2: Rows(9903) and Columns(38)

我的疑问是,我可以在Android应用程序在本地存储这么多的数据或应用程序的速度可以被它影响。

My doubt is that can i store this much data locally in an android application or the application's speed can be affect by it.

我不想这些数据存储在外部存储设备。我不能把它存储在服务器上的数据库,因为我已经在应用程序中使用这些数据很多次。而其它数据是在服务器上,因为它必须集中使用。

I don't want to store these data in external storage. And I can't store it on server database as I have to use these data many times in the application. While the other data is on server as it must be used centrally.

这是我的观点。但请给我你的建议。

This is my point of view. But please give me your suggestions.

怎么做,如果有数据库的大小等。

What to do if there is such size of database.

请帮助我。在此先感谢...:)

Please help me. Thanks in advance...:)

推荐答案

的最大数据库大小约为1.4E + 14个字节(TB级140,或14万千兆字节)。

The maximum database size can be approximately 1.4e+14 bytes (140 terabytes, or 140,000 gigabytes).

参考:官方SQLite的文档和限制

14。最大数据库大小

每个数据库都包含一个或多个页。内的单个数据库,每一页具有相同的尺寸,但不同的数据库可以具有页大小是和65536两者之间512,包容的权力。一个数据库文件的最大尺寸为2147483646的页面。在65536字节的最大页面大小,这意味着大约1.4E + 14个字节(TB级140,或128 tebibytes,或14万千兆字节或128000 gibibytes)的最大数据库大小。

Every database consists of one or more "pages". Within a single database, every page is the same size, but different database can have page sizes that are powers of two between 512 and 65536, inclusive. The maximum size of a database file is 2147483646 pages. At the maximum page size of 65536 bytes, this translates into a maximum database size of approximately 1.4e+14 bytes (140 terabytes, or 128 tebibytes, or 140,000 gigabytes or 128,000 gibibytes).

这篇关于在Android应用程序最大的SQLite数据库大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆