Updating multiple tables at the same time in Linq-to-SQL
Posted
by kiran
on Stack Overflow
See other posts from Stack Overflow
or by kiran
Published on 2010-03-13T19:40:23Z
Indexed on
2010/03/13
19:45 UTC
Read the original article
Hit count: 434
How do I update two tables at the same time using Linq-to-SQL?
var z = from a in db.Products
join b in db.ProductSubcategories on
a.ProductSubcategoryID equals b.ProductSubcategoryID
join d in db.ProductCategories on
b.ProductCategoryID equals d.ProductCategoryID
select new { ProductName = a.Name, ProductCategory = d.Name,
ProductSubCategory = b.Name, Cost = a.StandardCost,
discontinuedDate = a.DiscontinuedDate,
ProductId=a.ProductID };
© Stack Overflow or respective owner