Randoom a Michael Friis production

LinqtoCRM and updating entities

There are some pitfalls when retrieving CRM entities with LinqtoCRM and trying to update them through the CRM web service. The most intuitive (but wrong) approach would be this:
var res = from c in p.Linq()
select c;

foreach (var con in res)
{
con.address1_line1 = “foo”;
service.Update(con);
}
This fails unfortunately. I think someone at Netcompany (my former employer) worked [...]


LinqtoCRM competitor and new version

A few days, a former collegue alerted me to xRM LINQ, a new commercial query provider for Microsoft CRM. I’ve downloaded the trial, of course, and it looks pretty good. xRM LINQ decided not to use usual web service classes and instead provide their own class generator/entity mapper (LinqtoCRM has one too, but only for [...]


Querying relationships with LinqtoCRM

I’ve just recorded a web cast demontrating joins with LinqtoCRM. The piece de resistance is a join across a many-to-many relationship with the intermediary class generated by CRMMetal:
var res = from u in p.Linq()
join sr in p.Linq() on u.systemuserid.Value equals sr.systemuserid.Value
join r in p.Linq() on sr.roleid.Value equals r.roleid.Value
[...]