views:

449

answers:

1

I having a weird problem with Entity Framework with MySql database.

Here's the code that I've got.

public class testbase
{
    private testEntities db = new testEntities();

    public IQueryable<post> GetRecords()
    {
        return db.record;
    }
}

Here record is a table in my database and this could should return all the rows in the table. I have only one row in there and when I do a db.record.Count(), I get 1.

But when I try to retrieve the rows themselves I get 'Function Evaluation timed out'.

What's happening? Anybody got any ideas?

+1  A: 

Okay, this turned out to be a dud question. Ben M was right. Some googling revealed: -

  1. EF does not behave well while debugging due to some issues in VS debugger. You get a 'Function evaluation timed out'.
  2. Things work swell when you try the code without debugging.

I was testing as I go for my new EF+MySql+ASP.Net.MVC app, and since I am a n00b at all three I didn't realize that.

I haven't deleted the question yet because there for others like me. It's on the community to decide whether to let this question survive or go.

I pronounce this question officially a dud.

Cyril Gupta
I don't think this question is a dud. I've been having a ton of issues getting my Silverlight + RIA Services + EF + MySQL app to work. I'm a "noob" as well, so I appreciate any insight I can get. Now if I can only figure out how to debug EF without debugging....wierd.
Ben McCormack