SQLServer 2005 中的类型 与 C# 中的类型 对应 关系
<Language from="SQL" To="C#">
<Type from="bigint" To="long" />
<Type from="binary" To="object" />
<Type from="bit" To="bool" />
<Type from="char" To="string" />
<Type from="datetime" To="DateTime" />
<Type from="decimal" To="decimal" />
<Type from="float" To="double" />
<Type from="image" To="byte[]" />
<Type from="int" To="int" />
<Type from="money" To="decimal" />
<Type from="nchar" To="string" />
<Type from="ntext" To="string" />
<Type from="numeric" To="decimal" />
<Type from="nvarchar" To="string" />
<Type from="real" To="float" />
<Type from="smalldatetime" To="DateTime" />
<Type from="smallint" To="short" />
<Type from="smallmoney" To="decimal" />
<Type from="text" To="string" />
<Type from="timestamp" To="byte[]" />
<Type from="tinyint" To="byte" />
<Type from="uniqueidentifier" To="Guid" />
<Type from="varbinary" To="byte[]" />
<Type from="varchar" To="string" />
<Type from="xml" To="string" />
<Type from="sql_variant" To="object" />
</Language>
<Language from="SQL" To="C# System Types">
<Type from="bigint" To="System.Int64" />
<Type from="binary" To="System.Object" />
<Type from="bit" To="System.Boolean" />
<Type from="char" To="System.String" />
<Type from="datetime" To="System.DateTime" />
<Type from="decimal" To="System.Decimal" />
<Type from="float" To="System.Double" />
相关文档:
继续SQLServer索引调优实践。这次探讨一下索引覆盖 - SQL Server主要使用索引去查询你需要的数据,当索引包括所有的你请求查询的字段,SQL Server将不需要去在表中查询。这个概念称做“索引覆盖”。
SQLServer2005的Non-clustered INDEX增加了一个“包含列(included column)
”选项。在 SQL Server 2 ......
// 按模版比例生成缩略图(以流的方式获取源文件)
//生成缩略图函数
//顺序参数:源图文件流、缩略图存放地址、模版宽、模版高
//注:缩略图大小控制在模版区域内
public static void MakeSmallImg(System.IO.Stream fromFileStream,string fileSaveUrl,System.Double templateWidth,System.Double templateHeight)
{ ......
sqlite官方站
http://www.sqlite.org/
SQL Syntax
http://www.sqlite.org/lang.html
sqlite中文站
http://www.sqlite.com.cn/
http://www.sqlitechina.org/
建立数据库档案
用sqlite3建立数据库的方法很简单,只要在shell下键入(以下$符号为shell提示号,请勿键入):
$ sqlite3 foo.db
如果目录下没有fo ......
连接Access
首先看一个例子代码片断:
程序代码:
--------------------------------------------------------------------------------
using System.Data;
using System.Data.OleDb;
......
string strConnection="Provider=Microsoft.Jet.OleDb.4.0;";
strConnection+=@"Data Source=C:\BegASPNET\Northwind.mdb" ......
SQL中有四种基本的DML操作:INSERT,SELECT,UPDATE和DELETE。
INSERT语句
用户可以用INSERT语句将一行记录插入到指定的一个表中。例如,要将雇员John Smith的记录插入到本例的表中,可以使用如下语句:
INSERT INTO EMPLOYEES VALUES
('Smith','John','1980-06-10',
'Los Angles',16,45000);
......