Print Page | Close Window

PassthruEsqlQuery

Printed From: IdeaBlade
Category: DevForce
Forum Name: DevForce 2009
Forum Discription: For .NET 3.5
URL: http://www.ideablade.com/forum/forum_posts.asp?TID=1470
Printed Date: 22-Sep-2025 at 3:50am


Topic: PassthruEsqlQuery
Posted By: mbevins1
Subject: PassthruEsqlQuery
Date Posted: 14-Sep-2009 at 10:09am
I am trying to run a query that looks like this:
 

parameterizedEsql =

SELECT VALUE oo FROM

Employees AS oo

WHERE oo.EmployeeID NOT IN

(SELECT DER.EmployeeID FROM DailyEmployeeRoute as DER WHERE DER.DailyVehicleRouteID IN

(SELECT DailyVehicleRouteID FROM DailyVehicleRoute as DVR WHERE DVR.RouteDate = '9/9/2009' ))

AND oo.isActive =1

AND oo.OperationID = 1

 

var query = new PassthruEsqlQuery(typeof(Employee), parameterizedEsql);

When i run it I get this error:
'DailyEmployeeRoute' could not be resolved in the current scope or context. Make sure that all referenced variables are in scope, that required schemas are loaded, and that namespaces are referenced correctly.
 
 
How do I go about running a query like this?
 
 



Replies:
Posted By: kimj
Date Posted: 14-Sep-2009 at 2:13pm

EF is expecting an EntitySet named "DailyVehicleRoute" in the conceptual model.  If you've used the pluralizer, the name is most likely "DailyVehicleRoutes".




Print Page | Close Window