public class Demo { public static void main(String[] args) { Scanner sc = new Scanner(System.in); System.out.println("请输入总记录数"); int total = sc.nextInt(); System.out.println("请输入每页显示多少条数据"); int size = sc.nextInt(); int page = total %…
SELECT @TotalCount=count(1) FROM TableA A WITH(NOLOCK) INNER JOIN TableB B WITH(NOLOCK) ON A.Id=B.Id WHERE A.Name=ISNULL(@name,A.Name) AND A.Age=ISNULL(@Age,A.Age) AND B.Address=ISNULL(@Address, B.Address) AND B.GoodsName like '%'+ISNULL(@GoodsName,'…
[Unity3D]做个小Demo学习Input.touches 学不如做,下面用一个简单的Demo展示的Input.touches各项字段,有图有真相. 本项目已发布到Github,地址在(https://github.com/bitzhuwei/AndroidTouchDemo). 制作Demo 很简单,只需拉一个Text,然后添加一个脚本. 脚本如下. using UnityEngine; using System.Collections; public class DisplayTouch…
简单的分页存储过程 CREATE PROC Paged @pageIndex INT, @pageCount INT OUTPUT, @pageSize INT AS DECLARE @count INT SELECT @count= COUNT(*) FROM dbo.Student SET @pageCount=CEILING(@count*1.0/@pageSize) SELECT * FROM (SELECT ROW_NUMBER() OVER(ORDER BY dbo.Student.…
只是一个用EF写的一个简单的分页方法而已 慢慢的写吧.比如,第一步,先把所有数据查询出来吧. //第一步. public IQueryable<UserInfo> LoadPagesForUserInfos(int pageSize, int pageIndex, out int total) { DataModelContainer db = new DataModelContainer(); total = db.UserInfo.Count(); )).Skip(pageSize).As…