Can anyone help me, to convert the below sql query to Linq (Lambda Expressions). Thanks in Advance.
SQL Query:
UPDATE A INNER JOIN B ON (A.Trade Number=B.Trade Number) AND (A.AccountId=B.AccountId) SET A.Float = B.CCY, A.Fl开发者_开发技巧oat = B.BASIS, A.LastReset = B.FIXING, A.LastLibor = B.INTRATE;
Updates are not expressed as LINQ statements. You can use LINQ to load the record you wish to modify, but the actual update will involve a separate method call, the details of which will depend on which database technology you're using.
So, assuming you already have a reference to the record you wish to update from A, load the associated record from B (using LINQ), perform the updates to A programatically, and then save the changes to A.
Here's an example using LINQ-to-SQL.
精彩评论