entity framework - Simple EF 5 Query brings back no results -



entity framework - Simple EF 5 Query brings back no results -

strange issue:

trying simple query against email notifications table:

using (mycontext context = new mycontext()) { iqueryable<emailnotification> query = context.emailnotifications.where(q => (q.lastsendattemptstatus == emailnotificationsendstatuses.pending) || (q.lastsendattemptstatus == emailnotificationsendstatuses.resend)); homecoming query.tolist(); }

it brings no results though rows there. in fact, looked @ sql generates , ran without changes, , does bring right results.

select [extent1].[emailnotificationid] [emailnotificationid], [extent1].[from] [from], [extent1].[to] [to], [extent1].[cc] [cc], [extent1].[bcc] [bcc], [extent1].[subject] [subject], [extent1].[body] [body], [extent1].[lastsendattempton] [lastsendattempton], [extent1].[lastsendattemptstatus] [lastsendattemptstatus], [extent1].[failurecomments] [failurecomments] [dbo].[emailnotifications] [extent1] (0 = cast( [extent1].[lastsendattemptstatus] int)) or (3 = cast( [extent1]. [lastsendattemptstatus] int))

any hints on should checking?

sorry this. turned out connection string issue.

entity-framework

Comments

Popular posts from this blog

javascript - mongodb won't find my schema method in nested container -

Hibernate criteria by a list of natural ids -

ios - Lagging ScrollView with UIWebview inside -