score:3

Accepted answer

you can do that with:

where updatedObjects.Any(uo => uo.ID == o.ID)

score:0

You should be looking to implement batch updates with linq for example like it's described at http://www.aneyfamily.com/terryandann/post/2008/04/Batch-Updates-and-Deletes-with-LINQ-to-SQL.aspx

score:0

You could create a lambda or another method that performs the check for you; for example

where IDMatches(o.ID, updatedObjects)

and then define IDMatches as a simple iteration over updatedObjects.

static void IDMatches(int id, List<MyObject> updatedObjects)
{
    foreach (MyObject updated in updatedObjects)
    {
        if (id == updated.ID)
            return true;
    }
    return false;
}

Related Query