摘要:
查询句法:var 构建匿名类型1 = from c in ctx.Customers select new { 公司名 = c.CompanyName, 地址 = c.Address };对应SQL:SELECT [t0].[CompanyName], [t0].[Address]FROM [dbo].[Customers] AS [t0] 描述:查询职员的姓名和雇用年份查询句法:var 构建匿名类型2 = from emp in ctx.Employees select new { 姓名 = emp.LastName + emp.FirstName, 雇用年 = emp.HireDate.V 阅读全文