青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品

程序讓生活更美好

半畝方塘 天光云影

  C++博客 ::  :: 新隨筆 :: 聯系 ::  :: 管理 ::
  55 隨筆 :: 4 文章 :: 202 評論 :: 0 Trackbacks

Features and Limitations

特性和局限性

In this section we will look at the key features of SQLite and some of its limitations. The nature of SQLite makes it an ideal choice for quite a number of tasks, but it's not suitable for everything.

在本部分我們將要看一下SQLite關鍵特性和它的一些局限性。SQLite的本質使它成為許多任務的理想選擇,但它并不適合所有的方面。

It is important to decide whether SQLite or any other database engine for that matteris the right choice for your application before committing to a particular technology.

在為你的應用確定一個特殊的技術之前,決定選擇使用SQLite或者其它的任何數據庫引擎作是非常重要的。

Speed

速度

SQLite is extremely efficient, benefiting from a highly optimized internal architecture and a small memory footprint. Because SQLite is not a client/server database, the overheads of running a database daemon and socket communication are eliminated.

SQLite 非常高效,這得益于高度優化的內部結構和很小的內存需求。因為SQLite 不是一個客戶端/服務器類型的數據庫,運行一個數據庫進程和套接字通信的開銷被消除了。

The published speed comparison at
http://www.sqlite.org/speed.html compares SQLite to both MySQL and PostgreSQL. It finds that SQLite can perform up to 20 times faster than PostgreSQL and more than twice as fast as MySQL for common operations.

http://www.sqlite.org/speed.html 上的發表了它和MySQL和PostgreSQL速度對比。對比表明,SQLite在執行普通操作的時候速度比PostgreSQL快20倍,是MySQL的兩倍。


These tests were performed with default installations of each database, and although it is possible to tune the MySQL and PostgreSQL servers for slightly better performance in a given environment, SQLite does not require any such optimization.

這個是在每個數據庫的默認安裝情況下測試的,盡管在給定的環境中調整之后,MySQL和 PostgreSQL 的執行情況會略有提高,但是SQLite是不需要任何優化的。


The tests found that SQLite is significantly slower than the other databases only on the operations to create an index and to drop a table. However, slowness in these areas will not affect performance on a production database.

這個測試發現,SQLite僅僅在執行創建索引和刪除表的操作時速度要比其他數據庫慢得多。然而,這些方面得低速并不會影響到作為一個生產數據庫。

Portability

移植性

Because SQLite databases are stored as single files on the filesystem, they are very portable indeed. A database can be copied from one file to another, even across different operating systems. This means that for a cross-platform distribution you just need to concentrate on making your code portable even when a populated database is to be shipped with the application.

因為SQLite數據庫在文件系統上是作為單個文件存儲的,實際上它們是非常容易移植的。一個數據庫可被從一個文件拷貝到另一個文件,甚至是跨越不同的操作系統。這意味著在有一個交叉平臺上發布的時候,你只需要關注于使你的代碼,使其可以移植,甚至是當一個可移植的數據庫是和應用一起發布的。

SQLite has no external dependencies. The SQLite library is self-contained, so the only system requirement to run an application with an embedded SQLite database is the SQLite library itself. Because SQLite can be freely distributed, you can always ensure that this is present.


SQLite沒有額外的依賴性。SQLite 庫是自持的,因此在運行嵌入式SQLite數據庫的時候,僅僅需要的是SQLite的庫本身。因為SQLite能夠自由的發布,你總是可以確保這是可行的。

Security
安全

SQLite databases are stored to the filesystem and access control is performed by the underlying operating system based on that file's permission settings.
?SQLite 數據庫存儲在文件系統之上,訪問控制是由基于操作系統之下的的文件權限設定來實現的

Though SQLite can be accessed by processes running as different users if the correct file permissions are set, the database engine does not detect which user is performing a particular operation.

如果正確的文件訪問權限設定了,盡管SQLite能夠通過進程運行作為不同的用戶來被訪問,但是數據庫引擎并不檢測哪個用戶正在執行一個特別的操作。

The advantage of this is one of administrative simplicitythere is no need to set up a complex user grants scheme. Any user who has access to read the database file is able to access the database tables and records. Likewise, in a shared environment, users are able to create their own SQLite databases to their file space without any involvement from the system administrators.

它的優點之一就是管理簡單,不需要設定復雜的用戶授權模式。任何擁有訪問權利的用戶都可以訪問數據庫表格和記錄。同樣,在一個共享環境中,用戶可以在他們的自己的文件空間上創建他們自己的SQLite數據庫而不用涉及系統管理。

The disadvantage comes when you want to control permissions at a more finely grained level. There is no GRANT operation that would allow access to particular tables to one set of users but not others. If users have read access, they are able to read the entire database, and if they have write access, you have to be sure of their competence and trustworthiness with the data!

缺點是,當你需要在更加細致粒度水平的控制權限的時候,它沒有GRANT操作,這個操作允許一部分用戶可訪問特定的表而另一部分用戶不行。當用戶擁有訪問許可,他們能夠讀整個數據庫,如果他們有寫許可,你必須要確定他們在數據上的的權限和信賴度

SQL Implementation

SQL工具

SQLite supports a large subset of the ANSI SQL-92 standard. Some features have a limited implementation and a few features are not supported at all.

SQLite支持ANSI SQL-92標準的大的子集。某些特性有一個有限的工具,其他一些特性并不都被支持。
For example, atomic transactions are available but cannot be nested; simple subqueries are possible but correlated subqueries are not; triggers can fire for each row but not for each statement; views are available but are read-only.

例如,原子事務是可用的,但不能嵌套;簡單的子查詢是可以的,但相互關聯的子查詢是不行的;觸發器可以在每一行觸發,但不能在每個語句上觸發;視圖是可見但是只讀的。
The list of current limitations is maintained at
http://www.sqlite.org/omitted.html with the items at the top of the list indicating which items are most likely to be added to SQLite first.

目前被維護的局限性列表在 http://www.sqlite.org/omitted.html 上,列表的上部的選項指示了哪些選項最有可能被先加入到SQLite
In the vast majority of cases, none of the limitations of SQLite will cause problems when developing your application. For those that you need to work around, the benefits of using a fast, portable embedded database will almost certainly outweigh the cost of the workaround.

在大部分的情況下,SQLite的局限性不會給你的應用開發造成任何問題。因此,你需要變通的方法,使用一個快速的,可移植的嵌入式數據庫的好處將比變通方法的費用好的多。

Customization

定制

The SQLite library includes a very powerful mechanism for adding user-defined functions to the SQL command set. Custom functions can even be written in many of the supported language APIs, not just C/C++.

?

Additionally, as the SQLite source code is public domain, you are free to examine and modify it as you see fit. If SQLite is missing a feature that you absolutely must have, why not add it yourself and give something back to the community?

此外,因為SQLite的源代碼是開放的,你可以自由的檢查和修改只要你認為合適。如果SQLite現在缺少一個你很需要但卻還沒有的特性,為什么不自己添加然后給社區回贈一些呢?

Supported APIs

SQLite now has extensive support for other programming languages through APIs that use the underlying C/C++ interface to communicate with SQLite database files.

C/C++

The core interface is implemented as a single library called libsqlite.so on Linux/Unix systems and sqlite.dll on Windows.

Only the SQLite library is required to allow all users to create their own databases, so very little administration is required to add SQL database capability to a shared system.

PHP

Support for SQLite in PHP has been available for a while, but since the release of PHP 5, it has been shipped with the standard distribution.

Traditionally, PHP and MySQL have gone hand in hand as the interface and back end for dynamic web sites, but it is expected that many more web hosting providers will offer SQLite as PHP 5 gains popularity. From the host's point of view, it is much simpler to administer than a client/server database as there are no complex permissions to manage and database files will be already counted in the disk quota.

Note

SQLite has proved itself to work very well with low- to medium-traffic web sites. As a very rough guideline, if you are expecting over 100,000 hits per dayand in practice, only a small number of web sites will have this level of trafficyou should consider how much database work is done by the web scripts and think about doing some kind of stress testing before committing to SQLite as your back end.


Perl

Perl allows access to SQLite through the Database Interface (DBI) module. This makes it very easy for existing Perl developers to use SQLite within their scripts. The DBI provides an abstraction layer to the Database Driver (DBD), so the same command set is used to access many different types of underlying databases.

The DBD::SQLite driver further allows access to the capabilities of SQLite that the Perl DBI does not allow. Although this does not create a Perl application that can be easily ported to another database back end, it does allow access to the powerful user-defined functions feature.

Tcl

The Tcl interface for SQLite is shipped as part of the SQLite distribution as a library that is imported into Tcl to activate the extensions.

Using Tcl and Tk together with SQLite, you have a platform that is ideal for rapid development of portable graphical user applications.

Other Programming Languages

SQLite has APIs for many other programming languages, including Java, .NET, Smalltalk, and Ruby. As more languages become supported, they are added to the list at http://www.sqlite.org/cvstrac/wiki?p=SqliteWrappers .

Scalability

The downside of using a single file to store databases is that SQLite is not as scalable as many client/server database systems.

The SQLite engine can address database files of up to 2TB in size; however, the restriction on the size of a database is more likely to be enforced by your operating system. In many cases, the size limit on a single file is 2GB.

File locking in SQLite is very coarse-grained. When a write operation takes place, the entire file is locked so that no other process can open it for reading or writing. Larger RDBMSs implement locking at the table or row level so that other processes are able to carry on working unless they are trying to access a specific piece of locked data.

Therefore, if you have a database that is likely to involve massive database files or a high frequency of slow write operations, SQLite may not be suitable and you should consider an RDBMS that is designed and tuned for multiple-user access.

?????????????????????摘自《SQLite》Chris?Newman
posted on 2006-05-31 22:25 北風之神007 閱讀(811) 評論(0)  編輯 收藏 引用 所屬分類: SQLite
青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品
  • <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            新片速递亚洲合集欧美合集| 美女诱惑一区| 影音先锋在线一区| 久久精品国产亚洲一区二区三区| 亚洲男人第一网站| 一区在线免费观看| 欧美在线黄色| 午夜国产欧美理论在线播放| 亚洲天堂男人| 欧美成人免费网| 欧美一区二区视频网站| 最新国产乱人伦偷精品免费网站 | 久热爱精品视频线路一| 亚洲国产一区二区三区a毛片| 一本色道久久综合亚洲精品不卡| 国产精品久久久久久av福利软件 | 日韩亚洲欧美成人| 狼人天天伊人久久| 伊人激情综合| 国产嫩草影院久久久久 | 欧美日韩精品免费看| 亚洲综合日韩中文字幕v在线| 亚洲经典自拍| 欧美激情在线播放| 欧美一区二区三区在线播放| 亚洲天堂第二页| 亚洲乱码国产乱码精品精可以看| 亚洲东热激情| 亚洲国产欧美另类丝袜| 激情伊人五月天久久综合| 欧美日韩在线播放一区二区| 欧美日韩美女在线观看| 亚洲午夜精品久久久久久浪潮 | 欧美国产精品中文字幕| 久久亚洲精品伦理| 美女亚洲精品| 欧美激情 亚洲a∨综合| 久久久久久亚洲精品不卡4k岛国| 一本色道综合亚洲| 黄色成人在线| 免费观看国产成人| 欧美精品在线网站| 国产精品国产三级国产aⅴ入口| 欧美区在线播放| 国产精品a久久久久久| 欧美体内谢she精2性欧美| 国产精品v亚洲精品v日韩精品 | 久久精品国产一区二区电影| 亚洲区欧美区| 久久久精品性| 国产视频一区三区| 午夜欧美不卡精品aaaaa| 99热精品在线| 欧美视频日韩| 亚洲欧美电影院| 一区二区三区久久网| 欧美成人精品在线观看| 亚洲黄色在线观看| 久久人人精品| 悠悠资源网亚洲青| 久久免费观看视频| 久久国产欧美精品| 黄色欧美成人| 巨胸喷奶水www久久久免费动漫| 欧美亚洲尤物久久| 国产精品久久久久久亚洲毛片| 亚洲视频网站在线观看| 日韩视频―中文字幕| 欧美午夜剧场| 久久国产精品第一页| 欧美亚洲三区| 亚洲韩国青草视频| 亚洲精品男同| 国产精品久久久久影院色老大| 亚洲小说区图片区| 亚洲一区三区视频在线观看| 国产美女精品人人做人人爽| 久久综合久久久| 欧美成人69| 亚洲手机成人高清视频| 亚洲综合丁香| 亚洲国产精品成人精品| 亚洲人成网在线播放| 另类天堂视频在线观看| 亚洲免费黄色| 亚洲一区二区在线播放| 国产一区二区丝袜高跟鞋图片| 久久免费高清| 欧美日韩精品欧美日韩精品 | 欧美aⅴ99久久黑人专区| 蜜臀va亚洲va欧美va天堂| 99在线精品视频在线观看| 亚洲小视频在线观看| 在线观看成人av| 9l国产精品久久久久麻豆| 国产精品久久九九| 久久精选视频| 欧美精品日韩| 久久国内精品自在自线400部| 久久国产精品久久久久久电车 | 久久天堂精品| 欧美激情亚洲综合一区| 欧美一级二级三级蜜桃| 欧美成年人视频网站| 久久精品1区| 欧美日一区二区在线观看| 麻豆成人av| 国产精品日产欧美久久久久| 亚洲大黄网站| 黄色日韩在线| 午夜日韩视频| 亚洲一线二线三线久久久| 久久亚洲精品网站| 久久精品72免费观看| 欧美视频观看一区| 亚洲欧洲视频| 亚洲精品一区在线观看| 久久爱www.| 久久精品国产综合精品| 国产日韩一区在线| 亚洲免费中文字幕| 美女爽到呻吟久久久久| 久久久91精品| 国产精品最新自拍| 中文有码久久| 亚洲精品中文字幕在线| 欧美一级夜夜爽| 香蕉成人伊视频在线观看| 欧美日韩精品一二三区| 91久久在线| 亚洲美女福利视频网站| 免费看成人av| 久久午夜电影网| 久久精品国产精品亚洲综合| 亚洲午夜久久久久久尤物| 亚洲男女毛片无遮挡| 日韩视频在线永久播放| 亚洲少妇在线| 欧美日韩国产三区| 亚洲国内高清视频| 亚洲国产视频a| 欧美成人一区二区在线| 男人的天堂成人在线| 红桃视频成人| 久久久999成人| 欧美大片在线观看| 亚洲精品国精品久久99热| 免费人成精品欧美精品| 欧美chengren| 日韩天天综合| 国产精品成人播放| 亚洲一区日韩在线| 久久亚洲精品一区二区| 在线免费观看日本欧美| 蜜臀a∨国产成人精品| 亚洲欧洲三级| 亚洲欧美激情在线视频| 国产婷婷色一区二区三区在线| 国产一区二区三区最好精华液| 国内一区二区三区| 亚洲日本成人在线观看| 亚洲美女电影在线| 禁断一区二区三区在线| 蜜桃av一区二区三区| 亚洲欧洲免费视频| 欧美亚洲自偷自偷| 黑人极品videos精品欧美裸| 美女爽到呻吟久久久久| 亚洲黄一区二区| 小嫩嫩精品导航| 亚洲国产精品电影| 欧美色综合天天久久综合精品| 亚洲免费影视| 91久久精品国产91性色| 小黄鸭精品aⅴ导航网站入口| 曰本成人黄色| 欧美小视频在线| 免费日韩av| 欧美亚洲视频| 99精品热视频| 欧美国产日韩视频| 久久精品国产999大香线蕉| 亚洲福利在线观看| 国产精品美女久久久浪潮软件| 久久欧美中文字幕| 这里只有精品在线播放| 久久综合成人精品亚洲另类欧美| 99天天综合性| 欧美成人国产| 久久精品人人做人人综合| 99视频精品在线| 在线观看亚洲一区| 国产日韩欧美自拍| 欧美三日本三级少妇三2023| 久久婷婷人人澡人人喊人人爽| 亚洲欧美成aⅴ人在线观看| 亚洲日本无吗高清不卡| 欧美高清视频www夜色资源网| 久久国产精品99精品国产| 亚洲欧美在线一区二区|