Feeds:
Posts
Comments

Posts Tagged ‘ado.net-data-services’

Another day, another Data Services issue. This time the error message was “Too many table names in the query. The maximum allowable is 256.” Turns out this is caused by my organization’s use of Sql Server 2005 rather than Sql Server 2008. Unfortunately, it’s not very feasible to reduce the number of tables being used as that number is dependent on the query being made against the ADO.NET Data Services web service by an end user. And as there are very valid reasons to make queries that require many tables it doesn’t make sense to place limits even if they were feasible.

See the object named “Tables per SELECT statement” for each version of Sql Server…

Maximum Capacity Specifications for SQL Server 2005 (256)

Maximum Capacity Specifications for SQL Server 2008 (Limited only by available resources)

Read Full Post »

Seems like any direction I turn, if I try to get very clever I hit a wall with ADO.NET Data Services.

It looks like Linq to ADO.Net Data Services doesn’t support expressions/predicate builder (see comments on Cameron MacFarland’s post for details), so this wouldn’t work for this situation – might just have to wait for Linq to ADO.Net Data Services to support that functionality.

via Does LINQ Support Composable “OR Queries”? – Stack Overflow.

Read Full Post »

When my ADO.NET Data Services web service started throwing SqlCommand timeout messages I hit up Google and finally found a post in German(?) that pointed me in the right direction. The problem seems to be the Entity Framework Connection CommandTimeout, which can be easily modified overloading the OnStartProcessingRequest event.

When working with the ADO.NET Data Services (aka Astoria) we eventually get to the point that the tasks become more complicated and increases the load on the server. In solchen Situationen ist man mit potentiellen Timeouts in allen Ebenen konfrontiert. In such situations one is confronted with potential time-outs at all levels. In diesem Post zeige ich welche Timeouts es gibt, aber speziell will ich zeigen wie ich das Timeout des Entity Frameworks (SQL) in Kombination mit der MS REST Schicht ADO.NET Data Services anpassen kann. In this post I will show that there is a timeout, but specifically I want to show how the timeout of the Entity Framework (SQL) in combination with the MS REST can adjust layer ADO.NET Data Services.

ADO.NET Data Services, Entity Framework, and SQL / HTTP Timeouts

Read Full Post »

Find yourself just needing the darn data rather wasting time with lazy this and that? Give .Include (or .Expand I believe fora data service query) a try.

If you want to do eager loading with the Entity Framework it is generally really easy, you simply write something like this:

var results = from post in ctx.Posts.Include(“Comments”)
where post.Author.EmailAddress == “alexj@microsoft.com”
select post;

via Meta-Me : Tip 22 – How to make Include really Include.

Read Full Post »

Quick overview of the alternatives for querying using ado.net data services.

Use LINQ to ADO.Net Data Services to query the service. Again, since the DataServiceQuery is an IQueryable, you can use LINQ syntax to query it:

var query = (from p in svc.Posts
where p.PostID > 3
orderby p.PublishDate
select p).Skip(2).Take(2);

via Querying using DataServiceContext and DataServiceQuery – linyusen的专栏 – CSDN博客.

Read Full Post »

My service is broke-a$….er I mean my friend is having issues with his code and this is the link I sent him.

By default, Data Services don’t return information on what’s wrong when you try to execute some code, for example an update, against it. This is understandable: if you open up a data service on the web, you shouldn’t be returning all important information about entities in the underlying model.

However, when developing a Data Service, it might be handy to get a little more information than just “An error occurred while processing this request”. Here’s how to achieve this…

via Snowball – The Blog – Debugging ADO.NET Data Services.

Read Full Post »

ADO.NET Data Services provides filtering options for free.

What can go in a $filter? The most basic thing to do is to test properties of the resources we’re returning, which you can access simply by name, like we have done above. Literals for things like strings and numbers use the same syntax as in the key portion (see my last post and the original URL post for more details).

via Marcelo’s WebLog : $filter Query Option in ADO.NET Data Services.

Read Full Post »