Tuesday, 20 August 2013

Obtaining BreezeJS Predicate equivalent on the Server Side

Obtaining BreezeJS Predicate equivalent on the Server Side

There are times when I wish to execute the same query on the server as I
do on the client when using the BreezeJS library.
Here's a trivial example. Imagine the results of a query are limited on
the client for paging using skip() and take(). An "Export" function would
allow the download of the unpaged dataset; ie: without the "take/skip"
restrictions.
Now in a simple "Select * from TableName" type of query, this is trivial,
but what if the breeze Predicate is complex, and dynamically created
(precluding using a well-known server side SQL View).
Ideally, I'd like to know the source code that the Breeze.js .NET client
uses to translate the Predicate into a Linq Where clause.



This isn't my best question I've ever posted, so if you're willing to
help, and need more info, please comment and I'll be happy to post an
example or more details.

No comments:

Post a Comment