In my lastest project implemented with EF 3.5 and ADO.NET Data Services, there was a constant need to geting entity objects from DB by ID(…). This generic routine retrieves an object (of the generated DataServiceContext types) by its respective Id of int, double, decimal, or Guid: public static T GetById(this DataServiceContext ctx, U id)  where [...]