Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8727259
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T08:24:17+00:00 2026-06-13T08:24:17+00:00

The question was originally asked at http://entityframework.codeplex.com/discussions/399499#post928179 . Good day! Please tell me if

  • 0

The question was originally asked at http://entityframework.codeplex.com/discussions/399499#post928179 .

Good day! Please tell me if it is wrong place to post this question.

I have a query as follows:

IQueryable<Card> cardsQuery =
  dataContext.Cards
  .Where(predicate)
  .OrderByDescending(kc => kc.SendDate)
  .AsQueryable();

Then I try:


Task<Card[]> result = cardsQuery.ToArrayAsync();

And then exception rises:

The source IQueryable doesn't implement IDbAsyncEnumerable<Models.Card>

I use modified version of ‘EF 5.x DbCotext generator’.

How to avoid it?

UPDATE

Important remark is that I have method to produce IQuerayble<Card> as follows:

class Repository {
  public IQueryable<Card> GetKudosCards(Func<Card, bool> predicate) {
    IEnumerable<KudosCard> kudosCards = kudosCardsQuery.Where(predicate);
     return kudosCards
            .OrderByDescending(kc => kc.SendDate)
            .AsQueryable();
  }
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T08:24:17+00:00Added an answer on June 13, 2026 at 8:24 am

    The problem is as follows.

    I have a method:

    class Repository {
      public IQueryable<Card> GetKudosCards(Func<Card, bool> predicate) {
        IEnumerable<KudosCard> kudosCards = kudosCardsQuery.Where(predicate);
        return kudosCards
                .OrderByDescending(kc => kc.SendDate)
                .AsQueryable();
      }
    }
    

    The problem is that kudosCards has type IEnumerable<KudosCard>. That throws exception. If I change predicate type to Expression<Func<Card, bool> predicate then everything works just fine.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This question was originally asked in askubuntu.com but got no attention so I think
I was asked to post this as a question on StackOverflow by http://twitter.com/jonathanjulian which
I originally asked this question on cstheory.stackexchange.com but was suggested to move it to
I originally asked this question on programmers.stackexchange.com, because I figured the answers would be
This question was originally asked for Android 1.6. I am working on photos options
Note: I originally asked this question about an hour ago but only recently realized
This question was originally asked for the objective-c programming language. At the time of
UPDATE (5 July 2013): I've learned much since I originally asked this question. In
I asked this question originally on SuperUser , but it looks like I'm much
I'm reposting this question from an earlier post because when I originally asked it,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.