随笔分类 -  Z History

过完的技术,进行存档
摘要:首先,== equality 等同,=== identity 恒等。==, 两边值类型不同的时候,要先进行类型转换,再比较。===,不做类型转换,类型不同的一定不等。下面分别说明:先说 ===,这个比较简单。下面的规则用来判断两个值是否===相等:1、如果类型不同,就[不相等]2、如果两个都是数值,... 阅读全文
posted @ 2014-09-26 11:08 Coding_Yong 阅读(238) 评论(0) 推荐(0)
摘要:1,一般处理程序中context.Response.ContentType = "text/plain",则 ajax参数中 也是 text 类型。2,一般处理程序中 转化为json数据格式:命名 空间:using Newtonsoft.Json;代码:string strjson = JavaS... 阅读全文
posted @ 2014-09-22 16:54 Coding_Yong 阅读(324) 评论(0) 推荐(0)
摘要:var name = "The Window";var object = { name: "My Object", getNameFunc: function () { return function () { return this.name; ... 阅读全文
posted @ 2014-09-19 17:51 Coding_Yong 阅读(191) 评论(0) 推荐(0)
摘要:http://xiaolele.iteye.com/blog/682287 阅读全文
posted @ 2014-09-19 17:26 Coding_Yong 阅读(247) 评论(0) 推荐(0)
摘要:var a = "Hello World";function test() { alert(window.a); // "Hello World" alert(a); //underfined JavaScript 在执行的时候 会对全局的变量(包括局部变量进行检测)... 阅读全文
posted @ 2014-09-19 15:27 Coding_Yong 阅读(202) 评论(0) 推荐(0)
摘要:原理:PageSize, PageIndex;升序 order by a asca的 值 大于, 上一页数据 最大的 a值。降序 order by a desca的 值 小于, 上一页数据 最小的 a值。代码实例USE [SZSQ]GO/****** Object: StoredProcedur... 阅读全文
posted @ 2014-09-16 09:43 Coding_Yong 阅读(794) 评论(0) 推荐(0)
摘要:继承时,派生类的方法表 添加了所有继承的虚方法 记录项,基类型变量只能访问派生类类型 对象方法表中 继承 基类的方法记录项。 阅读全文
posted @ 2014-08-20 15:19 Coding_Yong 阅读(847) 评论(0) 推荐(0)
摘要:public sealed class classroom { private List student = new List(); private List student1 = new List(); public List Student ... 阅读全文
posted @ 2014-07-24 10:41 Coding_Yong 阅读(644) 评论(0) 推荐(0)
摘要:http://blog.csdn.net/RonoTian/article/details/2900714 阅读全文
posted @ 2014-07-17 12:34 Coding_Yong 阅读(209) 评论(0) 推荐(0)
摘要:从A表随机取2条记录,用SELECT TOP 10 * FROM ywle order by newid()order by 一般是根据某一字段排序,newid()的返回值 是uniqueidentifier ,order by newid()随机选取记录是如何进行的newid()在扫描每条记录的时... 阅读全文
posted @ 2014-07-06 17:52 Coding_Yong 阅读(567) 评论(0) 推荐(0)
摘要:int32 =intint64 =long1byte=8bitunicode 占2btyeint32 占 1 btyelong 占 4 btye 阅读全文
posted @ 2014-07-06 15:32 Coding_Yong 阅读(749) 评论(0) 推荐(0)
摘要:一、抽象类:抽象类是特殊的类,只是不能被实例化;除此以外,具有类的其他特性;重要的是抽象类可以包括抽象方法,这是普通类所不能的。抽象方法只能声明于抽象类中,且不包含任何实现,派生类必须覆盖它们。另外,抽象类可以派生自一个抽象类,可以覆盖基类的抽象方法也可以不覆盖,如果不覆盖,则其派生类必须覆盖它们。... 阅读全文
posted @ 2014-06-29 11:28 Coding_Yong 阅读(39191) 评论(0) 推荐(8)
摘要:例证:string peom1 = "Kubla Khan";string peom2 = "Kubla Khan"; string peom3 = String.Copy(peom2); Boolean b1 = peom1.Equals(peom2); //true Boo... 阅读全文
posted @ 2014-06-26 11:00 Coding_Yong 阅读(582) 评论(0) 推荐(0)
摘要:byte 无符号 8 为整数,值为0-255;sbyte 有符号8位整数,-128~127;short 有符号16位整数,范围在-32768~32767ushort 无符号16位整数 0--32767int 有符号 32 位整数,-2147483648~2147483647uint 无符号32位整数... 阅读全文
posted @ 2014-06-26 09:48 Coding_Yong 阅读(1724) 评论(1) 推荐(1)
摘要:1,转换成32为或者64为的数字2,进行运算3,算出结果后为int32或者int64,进行类型转化得到自己需要的类型 阅读全文
posted @ 2014-06-26 09:47 Coding_Yong 阅读(834) 评论(0) 推荐(0)
摘要:ReferenceEquals()判断两个字符串是否指向相同的内存地址;(判断引用)Equals,先判断两个字符串有相同的内存位置,是则两个字符串相等;否则逐字符比较两个字符串,判断是否相等(先判断引用,在判断值是否相等)下面举一个例子看一下:view plaincopy to clipboardp... 阅读全文
posted @ 2014-06-26 09:32 Coding_Yong 阅读(533) 评论(0) 推荐(0)
摘要:C#中各种数据类型可以表示的数据的范围 C#中各种数据类型可以表示的数据的范围 BOOL型为int型,一般认为占4个字节,取值TRUE/FALSE/ERROR。 sbyte型为有符号8位整数,占1个字节,取值范围在-128 ~ 127之间。 bytet型为无符号16位整数,占2个字节,取值范围在0~ 阅读全文
posted @ 2014-06-19 13:06 Coding_Yong 阅读(28044) 评论(3) 推荐(2)
摘要:SELECT RIGHT (CONVERT(VARCHAR(20),CONVERT(DECIMAL(20,15),rand())),15) AS c_random_number 阅读全文
posted @ 2014-06-07 22:04 Coding_Yong 阅读(549) 评论(0) 推荐(0)
摘要:@@fetch_status是MicroSoft SQL SERVER的一个全局变量其值有以下三种,分别表示三种不同含义:【返回类型integer】0 FETCH 语句成功-1 FETCH 语句失败或此行不在结果集中-2 被提取的行不存在@@fetch_status值的改变是通过fetch next... 阅读全文
posted @ 2014-06-03 10:51 Coding_Yong 阅读(474) 评论(0) 推荐(0)
摘要:库是否存在ifexists(select*frommaster..sysdatabaseswherename=N'库名')print'exists'elseprint'notexists'-----------------判断要创建的表名是否存在ifexists(select*fromdbo.sys... 阅读全文
posted @ 2014-05-30 10:54 Coding_Yong 阅读(1446) 评论(0) 推荐(0)