SQL 2000 分页
SELECT TOP 10 *
from HumanResources.Employee
WHERE EmployeeID NOT IN (SELECT TOP 0 EmployeeID from HumanResources.Employee ORDER BY EmployeeID desc)
ORDER BY EmployeeID desc
————————————————————
SELECT TOP 分页大小 * from 表名 where 主键 not in (select top 当前页减1*分页大小 from 表名 order by 主键)
order by 主键
相关文档:
If the SQL data type is 'timestamp', we need to use ResultSet.getBytes() to retrieve its value. If the SQL data type is 'datetime', we can use ResultSet.getTimestamp(). It is said timestamp is interanlly saved as binary data.
try {
Class.forName("com.microsoft. ......
SQL Server CONVERT() 函数
定义和用法
CONVERT() 函数是把日期转换为新数据类型的通用函数。
CONVERT() 函数可以用不同的格式显示日期/时间数据。
语法
CONVERT(data_type(length),data_to_be_converted,style)
data_type(length) 规定目标数据类型(带有可选的长度)。data_to_be_converted 含有需要转换的值。styl ......
下列语句部分是Mssql语句,不可以在access中使用。
SQL分类:
DDL—数据定义语言(CREATE,ALTER,DROP,DECLARE)
DML—数据操纵语言(SELECT,DELETE,UPDATE,INSERT)
DCL—数据控制语言(GRANT,REVOKE,COMMIT,ROLLBACK)
首先,简要介绍基础语句:
1、说明:创建数据库
CREATE DATABASE data ......
SQL Server 加载驱动和url的语句则为
驱动包为com.microsoft.sqlserver.jdbc.SQLServerDriver
String driverName = "com.microsoft.sqlserver.jdbc.SQLServerDriver";
String dbURL = "jdbc:sqlserver://localhost:1433; DatabaseName=sample";
驱动包为com.microsoft.jdbc.sqlserver.SQLServerDriver时
String driver ......
SQL Server之分布式事务
收藏
--> Title : SQL Server之分布式事务
--> Author : wufeng4552
--> Date : 2009-11-11
SQL Server之分布式事务
(一)概念:
分布式事务是涉及来自两个或多个源的资源的事务。Microsoft® SQL Serv ......