ADO.NET Data Services Hooking POC V3 .1

I just finished implementing the IUpdatable interfaceSmile

With ADO.NET Data Services, in the client part, you can use some LINQ queries which will be translated to an url. It’s really great to be able to use LINQ. However, this query is restrictive. For example, extension methods defined in the Queryable class aren’t allowed with ADO.NET Data Services (NotSupportedException).

When you add a web reference to your service, you will have some entity classes generated from the service metadata. If you have a relationship defined with a List<T>, or IEnumerable<T>, etc., in the server, the client generated code will use a System.Collections.ObjectModel.Collection. This class has a Count property. But when you want to use this on a LINQ query, you have a DataServiceQueryException. My ADO.NET Data Services Hooking POC solves it. Smile

Comments

# re: ADO.NET Data Services Hooking POC V3 .1

Matthieu,

The current v3.1 CodePlex download appears to be a T-SQL script, not source code for an IUpdatable implementation.

--rj

Sunday, October 19, 2008 10:51 AM by Roger Jennings

# re: ADO.NET Data Services Hooking POC V3 .1

Hi roger,

You're right. In fact, I just posted the DB generation script in the release because I think the interested part is the source code. I just added the dll in the release anyway.

Matthieu

Sunday, October 19, 2008 11:15 AM by Matthieu MEZIL

# re: ADO.NET Data Services Hooking POC V3 .1

Hi Matthieu

The initail test are still going on but i have not seen a way to insert a new object at this point.

I have tried creating a new object and adding to the context.

It returns a created to the service but nothing goes any further.

Have you got a test for Insert new object.

Just wondering if you have tried this yet?

Thanks

Martintr

Monday, October 27, 2008 12:23 AM by Martintr

# re: ADO.NET Data Services Hooking POC V3 .1

Hi Martin. I am very surprised by your message.

I create a Winform application which do this without problem.

var em = new Employee { Id = Guid.NewGuid(), LastName = "LN", Since = DateTime.Now };

_context.AddToEmployees(em);

_context.SaveChanges();

Monday, October 27, 2008 6:49 AM by Matthieu MEZIL

# Nice blog I should say

I should say that msmvps.com has lots of interesting information. Looks like the author did a good job. I will be coming back to msmvps.com for new information. Thank you.

Thursday, July 09, 2009 8:43 PM by Payday Loans Canada

# Nice blog by the way

msmvps.com is very informative. The article is very professionally written. I enjoy reading msmvps.com every day.

Saturday, August 08, 2009 8:28 PM by pay day loans vancouver

Leave a Comment

(required) 
(required) 
(optional)
(required)