.NET Compact Framework Data Provider for SQL Server CE
.NET Compact Framework Data Provider for SQL Server Mobile
Standard
Data Source=MyData.sdf;Persist Security Info=False;SQL Server Compact How to specify the location of the SDF file
Often times the .SDF database is not running in the current directory so it becomes necessary to programatically set the path to the SDF file. This is an example (.net C#) on how to do this when the SDF file is located in the same directory as the executing application.
Data Source=" + System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().GetName().CodeBase) + "\\MyData.sdf;
Persist Security Info=False;SQL Server Compact Specifying the maximum database size
The maximum size of the database is by default 128 MB. Override this by using the following connection string.
Data Source=MyData.sdf;Max Database Size=256;Persist Security Info=False;SQL Server Compact Specifying the maximum buffer size
The largest amount of memory that can be in use before the server starts flushing changes to disk is by default 640 kB. Override this by using the following connection string.
Data Source=MyData.sdf;Max Buffer Size=1024;Persist Security Info=False;SQL Server Compact Encryption enabled
Use this connection string to enable encryption on the database.
Data Source=MyData.sdf;Encrypt Database=True;Password=myPassword;
File Mode=shared read;Persist Security Info=False;The Encrypt Database="True" pair is really not necessary as the presence of the Password-parameter itself turns on encryption for the connection.
SQL Server Compact Exclusive access
Use this one to disallow other processes from opening or modifying the database while you have it open.
Data Source=MyData.sdf;File Mode=Exclusive;Persist Security Info=False;SQL Server Compact Read only access
Use this one to open a read-only copy of the database.
Data Source=MyData.sdf;File Mode=Read Only;Persist Security Info=False;SQL Server Compact Exclusive but shared for reading
Use this one to allow other processes to read, but not modify, the database while you have it open.
Data Source=MyData.sdf;File Mode=Shared Read;Persist Security Info=False;SQL Server Compact Specifying the maximum temp file size
The maximum size of the temporary database file is by default 128 MB. Override this by using the following connection string.
Data Source=MyData.sdf;Temp File Max Size=256;Persist Security Info=False;SQL Server Compact Case sensitive database
Upon database creation the default is case insensitive, use this one for a case sensitive database.
Data Source=MyData.sdf;Case Sensitive=True;Persist Security Info=False;This allows you to have multiple values, wich only deffer in lower / upper case, in a unique column.
This setting is a database creation time option and is ignored when connecting to an existing database
.NET Compact Framework Data Provider for SQL Server CE的更多相关文章
- Data Provider 中没有.net framework Data provider for Mysql 的解决方法
近来做的一个项目中,数据库用的是 MySql, 而在项目使用 Entity Data Model 来做数据服务层,可是在项目中添加 Data Entty Model 时,一般我们都会选择从数据库中直接 ...
- 解决VS2010在新建实体数据模型出现“在 .NET Framework Data Provider for Microsoft SQL Server Compact 3.5 中发生错误。请与提供程序供应商联系以解决此问题。”的问题
最近想试着学习ASP.NET MVC,在点击 添加--新建项--Visual C#下的数据中的ADO.NET 实体数据模型,到"选择您的数据连接"时,出现错误,"在 .N ...
- SQL SERVER 遇到Unable to find the requested .Net Framework Data Provider. It may not be installed. (System.Data)
今天新装的SQLSERVER 2012 EXPRESS 用于客户端程序 安装完成后打开登陆SQLSERVER 一切正常 当查看表定义.视图结构时,弹出一下内容 Unable to find the r ...
- 找不到请求的 .Net Framework Data Provider。可能没有安装.
学习中遇到的问题: 找不到请求的 .Net Framework Data Provider.可能没有安装. 找到的解决方法 解决方法: 安装Microsoft SQL Server Compact 4 ...
- .Net Framework Data Provider可能没有安装
方法一.下载SQL Server Compact 4.0 安装后就可以解决.下载地址是: http://www.microsoft.com/downloads/zh-cn/details.aspx?f ...
- 找不到请求的 .Net Framework Data Provider
1.安装 mysql-connector-net-6.9.10.msi 2.修改C:\Windows\Microsoft.NET\Framework\v4.0.30319\Config\machine ...
- 解决“找不到请求的 .Net Framework Data Provider。可能没有安装.”错误
问题: 这几天在装.NET 的开发环境,在装好VS2013和Oracle 11g之后,做了一个测试项目,运行调试没问题 但是涉及到数据库相关操作,如新建数据集.连接数据库等在调试的时候则会出现如下错误 ...
- CodeSimth - .Net Framework Data Provider 可能没有安装。解决方法
今天想使用CodeSimth生成一个sqlite数据库的模板.当添加添加数据库的时候发现: .Net Framework Data Provider 可能没有安装. 下面找到官方的文档说明: SQLi ...
- CodeSimth - .Net Framework Data Provider 可能没有安装
使用CodeSimth 连接SQLite数据库库 提示错误 codesmith 6以上的版本,说是支持sqlite生成,也有对应的sqliteprovider.dll,但是使用时却说Test fail ...
随机推荐
- RedHat和CentOS使用本地yum源配置
2013-04-01 11:38:30 标签:本地yum源 版权声明:原创作品,谢绝转载!否则将追究法律责任. 使用yum命令安装所需的软件,如果设备网络状况很好,当然也没必要去配置本地yum源,直接 ...
- httpcontext in asp.net unit test
[TestMethod] [HostType("ASP.NET")] [UrlToTest("http://localhost:25153/qq/a.aspx" ...
- Linux开启服务器问题(李蕾问题)
每次启动192.168.1.223服务器时,都要执行这个命令! #:service iptables stop
- python 读取SQLServer数据插入到MongoDB数据库中
# -*- coding: utf-8 -*-import pyodbcimport osimport csvimport pymongofrom pymongo import ASCENDING, ...
- msisdn与imsi简介
=======================================imsi========================================1 定义:imsi=MCC+MNC ...
- 求解 s = (1*1)!+(2*2)! + (3*3)!+...+(n*n)! (C语言)
提示:定义函数可以求阶乘,再定义函数求阶乘之和.1和0的阶乘是1,n(n > 1)的阶乘是n * (n-1) * (n - 2) * … * 1 //采用了函数嵌套调用和函数递归调用 //求解阶 ...
- sublime text 2 前端编码神器-快捷键与使用技巧介绍
介绍网址:http://www.xuanfengge.com/sublime-text-2-artifact.html
- 基于msys2工具集,自编译gcc-6.2.0、Qt-5.6.1-1和Qt-4.8.7(有nuwen.net网站提供的脚本)
好久没更新(其实大可不要经常更新吧),一直都是用Qt4,最近想着转向Qt5了,msys2是自带Qt的,但工具链经常会更新,依赖也较多,简便才方便,做了最后一组Qt工具的更新,如题,Qt-4.8.7作为 ...
- CPU Benchmarks
http://www.cpubenchmark.net/high_end_cpus.html 非常清楚~~~
- Python标准库之urllib,urllib2
urllib模块提供了一些高级接口,用于编写需要与HTTP服务器交互的客户端.典型的应用程序包括从网页抓取数据.自动化.代理.网页爬虫等. 在Python 2中,urllib功能分散在几个不同的库模块 ...