<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom"><title type="text">博客园_AnyKoro_分类_Linq相关</title><id>http://feed.cnblogs.com/blog/u/53802/category/235365/rss</id><updated>2012-05-27T23:39:40Z</updated><generator>feed.cnblogs.com</generator><link rel="alternate" type="text/html" href="http://www.cnblogs.com/JosephLiu/category/235365.html"/><link rel="self" type="application/atom+xml" href="http://feed.cnblogs.com/blog/u/53802/category/235365/rss"/><entry><id>http://www.cnblogs.com/JosephLiu/archive/2010/02/28/1675063.html</id><title type="text">【转】 LINQ TO SQL中的selectMany</title><summary type="text">首先看SelectMany的定义： Queryable中的SelectMany 方法:将序列的每个元素投影到一个 IEnumerable&lt;(Of &lt;(T&gt;)&gt;) 并将结果序列组合为一个 IQueryable&lt;(Of &lt;(T&gt;)&gt;) 类型的序列。(引用MSDN) 在用LINQ TO SQL 来写查询语句时,有一个selectMany的语句,它标示着一对多的关系,这篇文章我想说下在LINQ TO SQL中几种可以等同selectMany的用法。 系统转换成selectMany的条件: 1:语句中不包含join ,into; 2:需要2个以上的from</summary><published>2010-02-28T03:34:00Z</published><updated>2010-02-28T03:34:00Z</updated><author><name>AnyKoro</name><uri>http://www.cnblogs.com/JosephLiu/</uri></author><link rel="alternate" href="http://www.cnblogs.com/JosephLiu/archive/2010/02/28/1675063.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/JosephLiu/archive/2010/02/28/1675063.html"/><content type="text">首先看SelectMany的定义： Queryable中的SelectMany 方法:将序列的每个元素投影到一个 IEnumerable&lt;(Of &lt;(T&gt;)&gt;) 并将结果序列组合为一个 IQueryable&lt;(Of &lt;(T&gt;)&gt;) 类型的序列。(引用MSDN) 在用LINQ TO SQL 来写查询语句时,有一个selectMany的语句,它标示着一对多的关系,这篇文章我想说下在LINQ TO SQL中几种可以等同selectMany的用法。 系统转换成selectMany的条件: 1:语句中不包含join ,into; 2:需要2个以上的from</content></entry></feed>
