摘要: using System;using System.Collections.Generic;using System.Linq;using System.Text;/*from let where子句* 1、from 后面接的是查询主体,可以有任何数量个,指定了额外的数据集合并引入了要在之后运算的迭... 阅读全文
posted @ 2015-09-14 20:15 Alfred.Xu 阅读(369) 评论(0) 推荐(0) 编辑
摘要: using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace Linq联接{ class Program { public class Student { ... 阅读全文
posted @ 2015-09-14 19:53 Alfred.Xu 阅读(117) 评论(0) 推荐(0) 编辑
摘要: using System;using System.Collections.Generic;using System.Linq;using System.Text;/** 1、Linq查询结果有两种类型:一个是枚举,一个是标量(scalar)*/namespace Linq三种查询{ class ... 阅读全文
posted @ 2015-09-14 19:28 Alfred.Xu 阅读(256) 评论(0) 推荐(0) 编辑
摘要: using System;using System.Collections.Generic;using System.Linq;using System.Text;/* 1、匿名类型只能和局部变量配合使用,不能用于类成员* 2、匿名类型没有名字,必须用var关键词作为变量类型* 3、变量声明的三种形... 阅读全文
posted @ 2015-09-14 18:17 Alfred.Xu 阅读(135) 评论(0) 推荐(0) 编辑