SQLite数据库连接方式
http://blog.csdn.net/ZF101201/archive/2010/05/26/5626365.aspx
SQLite.NET
Type: .NET Framework Class Library
Usage: System.Data.SQLite.SQLiteConnection
Basic
Data Source=filename;Version=3;
Version 2 is not supported by this class library.
Using UTF16
Data Source=filename;Version=3;UseUTF16Encoding=True;
With password
Data Source=filename;Version=3;Password=myPassword;
Using the pre 3.3x database format
Data Source=filename;Version=3;Legacy Format=True;
With connection pooling
Connection pooling is not enabled by default. Use the following parameters to control the connection pooling mechanism.
Data Source=filename;Version=3;Pooling=False;Max Pool Size=100;
Read only connection
Data Source=filename;Version=3;Read Only=True;
Using DateTime.Ticks as datetime format
Data Source=filename;Version=3;DateTimeFormat=Ticks;
The default value is ISO8601 which activates the use of the ISO8601 datetime format
Store GUID as text
Normally, GUIDs are stored in a binary format. Use this connection string to store GUIDs as text.
Data Source=filename;Version=3;BinaryGUID=False;
Note that storing GUIDs as text uses more space in the database.
Specify cache size
Data Source=filename;Version=3;Cache Size=2000;
The Cache Size value measured in bytes
Specify page size
Data Source=filename;Version=3;Page Size=1024;
The Page Size value measured in bytes
Disable enlistment in distributed transactions
Data Source=filename;Version=3;Enlist=N;
Disable enlistment in distributed transactions
Data Source=filename;Version=3;Enlist=N;
Disable create database behaviour
If the database file doesn't exist, the default behaviour is to create a new file. Use the following parameter to raise an error instead of creating a new database file.
Data Source=filename;Version=3;FailIfMissing=True;
Limit the size of database
Data Source=filename;Version=3;Max Page Count=5000;
The Max Page Count is measured in pages. This parameter limits the maximum number of pages of the database.
Disable the Journal File
This one disables the rollback journal entirely.
Data Source=filename;Version=3;Journal Mode=Off;
Persist the Journal File
This one blanks and leaves the journal file on disk after a commit. Default behaviour is to delete the Journal File after each commit.
Data Source=filename;Version=3;Journal Mode=Persist;
Controling file flushing
Data Source=filename;Version=3;Synchronous=Full;
Full specifies a full flush to take action after each write. Normal is the default value. Off means that the underlying OS flushes I/O's.
2.Finisar.SQLite ADO.NET Data Provider
Standard
Data Source=mydb.db;Version=3;
The "Version" key can take value "2" for SQLite 2.x (default) or value "3" for SQLite 3.x
Create a new database
Data Source=mydb.db;Version=3;New=True;
Using compression
Data Source=mydb.db;Version=3;Compress=True;
Specifying Cache Size
The Cache Size value represents the amount of data pages that are held in memory. Try increase this value for speed improvements but don't forget to keep track of the applications memory usage.
Data Source=mydb.db;Version=3;Cache Size=3000;
3.SQLite3 ODBC Driver
Standard
DRIVER=SQLite3 ODBC Driver;Database=mydb.db;LongNames=0;Timeout=1000;NoTXN=0;SyncPragma=NORMAL;StepAPI=0;
.NET Framework Data Provider for ODBC
Bridging to SQLite3 ODBC Driver
This is just one connection string sample for the wrapping OdbcConnection class that calls the underlying ODBC Driver. See respective ODBC driver for more connection strings to use with this class.
DRIVER=SQLite3 ODBC Driver;Database=mydb.db;LongNames=0;Timeout=1000;NoTXN=0;SyncPragma=NORMAL;StepAPI=0;
SQLite数据库连接方式的更多相关文章
- SQL server 数据库连接方式分析
SQL server 数据库连接方式图示: ODBC和OLEDB连接的区别 ODBC(开放数据库互连):是Microsoft引进的一种早期数据库接口技术.它实际上是ADO的前身.早期的数据库连接是非常 ...
- 浅析B/S架构数据库连接方式
前言 在许许多多的B/S架构系统中都涉及到了数据库的链接,那么对于数据库连接的方式有哪些?可能出现的问题是什么? 目录 1.普通连接方式 2.单例模式 3.连接池 分析 普通连接: 下面是我们 ...
- SQLite加密方式 [转]
关于SQLite SQLite是一个轻量的.跨平台的.开源的数据库引擎,它的在读写效率.消耗总量.延迟时间和整体简单性上具有的优越性,使其成为移动平台数据库的最佳解决方案(如iOS.Android). ...
- WebForm(二)——控件和数据库连接方式
一.简单控件 1.Label(作用:显示文字) Web中: <asp:Label ID="Label1" runat="server" Text=&quo ...
- mysql数据库连接方式(.net)
1.通过ado.net连接(数据库连接串中库名称为中文无法使用) 需要添加MySql.Data.dll(可通过安装mysql-connector-net-6.8.3.mis获得) 引用MySql.Da ...
- 二、spring Boot构建的Web应用中,基于MySQL数据库的几种数据库连接方式进行介绍
包括JDBC.JPA.MyBatis.多数据源和事务. 一.JDBC 连接数据库 1.属性配置文件(application.properties) spring.datasource.url=jdbc ...
- beego中各类数据库连接方式
beego 框架是优秀得go REST API开发框架.下面针对beego中各类数据库连接操作做一个总结. 1. orm连接方式 beego中的orm操作支持三种数据库:mysql,sqlite3,p ...
- sql server 数据库连接方式分析、详解
本文链接:https://blog.csdn.net/wang379275614/article/details/7859398 一.OLEDB方式连接Sql身份验证模式:Provider=" ...
- Access数据库连接方式
网络连接:Provider=Microsoft.ACE.OLEDB.12.0;Data Source=\\server\share\folder\myAccessFile.accdb;标准安全:Pro ...
随机推荐
- LA 3641 (置换 循环的分解) Leonardo's Notebook
给出一个26个大写字母的置换B,是否存在A2 = B 每个置换可以看做若干个循环的乘积.我们可以把这些循环看成中UVa 10294的项链, 循环中的数就相当于项链中的珠子. A2就相当于将项链旋转了两 ...
- UVa 540 Team Queue 【STL】
题意:给出t个团体,这t个团体排在一起,每次新来一个x排队,如果在整个的团体队列中,有x的队友,那么x排在它的队友的后面,如果他没有队友,则排在长队的队尾 求给出的每一个出队命令,输出出队的人的编号 ...
- BZOJ 2179 FFT快速傅里叶
fft. #include<set> #include<map> #include<ctime> #include<queue> #include< ...
- Math.trunc
- 海康、大华IpCamera RTSP地址和格式
海康:rtsp://[username]:[password]@[ip]:[port]/[codec]/[channel]/[subtype]/av_stream说明:username: 用户名.例如 ...
- AngularJS:实现动态添加输入控件功能(转)
http://www.cnblogs.com/ilovewindy/p/3849428.html <!DOCTYPE html> <html> <head> < ...
- hdu 3038 How Many Answers Are Wrong(种类并查集)2009 Multi-University Training Contest 13
了解了种类并查集,同时还知道了一个小技巧,这道题就比较容易了. 其实这是我碰到的第一道种类并查集,实在不会,只好看着别人的代码写.最后半懂不懂的写完了.然后又和别人的代码进行比较,还是不懂,但还是交了 ...
- [Everyday Mathematics]20150106
(1). 设 $f\in C[0,T]$, $g$ 是 $T$-周期函数, 试证: $$\bex \vlm{n}\int_0^T f(x)g(nx)\rd x=\frac{1}{T}\int_0^T ...
- 再谈Jquery Ajax方法传递到action(转)
之前写过一篇文章Jquery Ajax方法传值到action,本文是对该文的补充. 假设 controller中的方法是如下: public ActionResult ReadPerson(Perso ...
- cocos2d-x 详解之 CCAction(动作)
关于动作部分,总的来说使用起来比较简单,创建一个动作,然后让可渲染节点如精灵去执行这个动作即可.cocos2dx提供了很多类型的动作,使用起来也很方便.本节重点介绍动作CCAction的子类之一时间动 ...