Last week I did a webinar for DevExpress on XPO, their object/relational mapping product. It went well, I had fun, and around 60 or so people stayed till the end, so it can’t have been half bad! 😉 If you would like to see the webinar, it’s now up on the DevExpress site – click this link to watch it. I had a few requests for the samples I was using and writing during the webinar, so I’m making them available for download. Have fun!
Here’s the download: XPOWebinar201103.zip
I’m replying to a post in the DevExpress XPO forum, where the question came up of how to use joins with XPO/LINQ and projection. Unfortunately, the forum system mangled my code snippets, so I thought I’d put the info up here as well.
Emilio Garcia wrote: I trying to create a linq query to retrive some objects, this is the query:
var listadoSesiones = from u in usuariosjoin s in sesiones on u.ObjId equals s.UsuarioIdwhere s.Activa == true orderby s.FechaInicio ascending select new { u.NombreUsuario, u.NombreCompleto, s.FechaInicio, s.FechaFin };
I found a forum post today about binding an XPO datasource to the DevExpress DXGrid control. I had posted about this on my DX blog before, but that is more than a year ago – things are moving along quickly, and this post is very likely going to be outdated again with 2010.1… but that’s life, isn’t it 😃
I have recently published a few more XPO related posts on the new Developer Express community site. Previously I have sometimes posted XPO stuff on this blog, and these posts are now all eaten up by the DX site – so I thought I’d let you know if you’re watching this space and not the DX community site. Here are the posts I wrote:
This has been announced today: There’s a Developer Express site now for blogs written by people working for the company. This is it: community.devexpress.com I have published two posts there so far, related to the newest major release of XPO (6.1): “Session Management and Caching” and “My persistent classes are real classes – or not?”.
I have just published this: Transactions and Units of Work
The next version of XPO (eXpress Persistent Objects) from Developer Express has finally been released. A list of new features is here. I’m currently working on a number of technical articles that will soon start to appear in the list on this page - look out for that if you’re into XPO. And if you’re not (yet), be sure to download a demo of the complete suite including XPO from here.
Well, if I’m wondering about that every now and then, I’m sure some of the more loyal readers of my blog must be wondering the same thing, given the sparse nature of blog updates in recent months. The answer is, since I’ve started working for Developer Express, I’ve been doing that many different things that it’s just hard to keep track of them, and I haven’t found myself with the free time needed to continually update my blog. But I see that this is a Bad Thing and I’ll try to do something about it. So what have I done? Let’s see:
Recently, there have been several requests in the XPO newsgroup about problems with serialization, in conjunction with ASP.NET. I’m still unclear if these issues all had the same sources, but when somebody approached me personally about this today, I thought I’d just look into the web services problem. Please note that I made these tests on the .NET 2 platform, so there may be differences to .NET 1.1. What’s more, ASP.NET and web services are not something I usually have much to do with, so I may certainly be missing something here and there.
Now, what is the problem? Simple: If you have a web method that returns a type that’s derived from one of the XPO base classes (XPObject or XPCustomObject, doesn’t matter), an exception will be thrown when you try to access the service:
Many things change with the decision to work with purely object-oriented data in a specific situation. The outlook seems good: business processes and rules will be much easier to implement, completely typed data will be no problem at all and there’ll be no more structural problems trying to accomodate clumsy handling of records and rows in an otherwise OO application structure. There’ll be an object/relational mapping tool that takes care of all the persistence issues. There’s one thing though that will pose problems much greater than originally anticipated, and it’s easy to overlook large parts of that in the original decision: the wide topic of data integrity in the object world (OW). I’m going to present some general questions and theories about data integrity in conjunction with OO data objects in this article and I’m planning to write some further articles on the same topic later. Occasionally I may reference the technology I’m personally using at the moment, which is .NET 2, the C# language and XPO.