zzz projects Entity Framework 6 EF 6
Home EF Core Articles Knowledge Base Online Examples
  • Home
  • EF Core
  • Articles
  • Knowledge Base
  • Online Examples

Entity Framework 6 - Knowledge Base (KB)

6940 results

Using entity framework, "order by Col1, Col2."

I need to order by 2 columns using the entity framework....How is that done?...return _repository.GetSomething().OrderBy(x => x.Col1 .. Col2)? ...i.e ...SELECT * FROM Foo ORDER BY Col1, Col2
.net c# entity-framework linq
asked by Lasse Edsvik

In Entity Framework, is it possible to see whether an object has previously been associated to a data context?

I am getting the following error when trying to attach an object that is already attached to a given context via ...context.AttachTo(...)...:...An object with the same key already exists in the ObjectStateManager. The ObjectStateManager cannot track multi...
.net entity-framework
asked by joshcomley

Timeout Expired While Generating Model in Entity Framework with MySQL

I've constructed a database in MySQL and I am attempting to map it out with Entity Framework, but I start running into "GenerateSSDLException"s whenever I try to add more than about 20 tables to the EF context....An exception of type 'Microsoft.Data.Ent...
edmgen entity-framework mysql
asked by Nathan Taylor

ObjectContext.Refresh()?

How to update ALL the dirty entities from the data store, and reset their changed values to the original store value?...The method ...ObjectContext.Refresh... requires as a parameter the entities to be refreshed.
dirty-data entity-framework objectstatemanager refresh reload
asked by Shimmy

Non-EF method calls in the select clause

I'm having trouble building an Entity Framework LINQ query whose select clause contains method calls to non-EF objects....The code below is part of an app used to transform data from one DBMS into a different schema on another DBMS. In the code below, Ro...
c# entity-framework linq linq-to-entities postgresql
asked by Justin Grant

Validate data with WPF and Entity Framework using DataAnnotations?

Is there any way to validate using DataAnnotations in WPF & Entity Framework?
.net data-annotations entity-framework validation wpf
asked by Shimmy

Issues with Entity Framework One-to-One Mapping

Using VS 2010 beta 2, ASP.NET MVC....I tried to create an Entity framework file and got the data from my database....There were some issues with the relationships, so I started to tweak things around, but I kept getting the following error for simple one-...
entity-framework
asked by Omar

Is it feasible to do an outside join with Linq to Entity Framework?

There are many examples of outer join using Linq to Sql, all of them hinging on ...DefaultIfEmpty()... which is not supported with Linq to Entity Framework....Does this mean that outer join is not possible with Linq to Entity using .NET 3.5 (I understand ...
entity-framework left-join linq
asked by Ralph Shillington

Multiple tables are mapped to one object using Entity Framework.

I have a database with a table for active orders and one for inactive orders. I would like to model this in Entity Framework as one entity called Orders. I also need a way to determine if an order in this collection is active or not, preferably by having ...
entity-framework
asked by Jacob Adams

Endpoint Multiplicity in Entity Framework

Say I have 3 tables in a Tennis Application (stripped down removing irrelevant info):...Competitions...Id (PK)...Matches...Id (PK)...CompId (FK)...CourtAssignments...CompId (PK),(FK)...CourtNumber (PK)...MatchId (FK), (Unique)...To describe the above: A m...
database-design entity-framework
asked by Scott

Is there a mechanism to compare EntityObject values for equal values in Entity Framework?

Is there a simple way to compare two EntityObjects for value-equality. I simply want to check if all the database-values are the same, so I don't care if the EntityKey is different. ...Is this possible built-in? Or should I just write my own method. ...I ...
entity-framework equality
asked by Peterdk

In Entity Framework, what is the best approach to see whether an object exists?

What is the best way to check if an object exists in the database from a performance point of view? I'm using Entity Framework 1.0 (ASP.NET 3.5 SP1).
entity-framework exists linq-to-entities
asked by Freddy

Change the database schema of Entity Framework during runtime.

In most asp.net applications you can change the database store by modifing the connectionstring at runtime. i.e I can change from using a test database to a production database by simply changing the value of the "database" field in the connectionstrin...
asp.net c# entity-framework
asked by user48545

"The store update, insert, or delete statement impacted an unexpected amount of rows (0)," says Entity Framework.

I am using Entity Framework to populate a grid control. Sometimes when I make updates I get the following error:...Store update, insert, or delete statement affected an unexpected number of rows (0). Entities may have been modified or deleted since entiti...
entity-framework
asked by strongopinions

How may Entity Framework be wrapped to intercept LINQ expressions right before they are executed?

I want to rewrite certain parts of the LINQ expression just before execution. And I'm having problems injecting my rewriter in the correct place (at all actually)....Looking at the Entity Framework source (in reflector) it in the end comes down to the ...
c# entity-framework expression-trees linq
asked by Davy Landman

SQL update query in Zend Framework

How would I write this SQL the Zend Framework way?...UPDATE register SET balance = (balance + 10) WHERE added_date > 1259944184 ; ...I can't find any examples of this on Zend's website or the web....Do I need to use "...Zend_Db_Expr..."?
entity-framework sql sql-update zend-framework
asked by EricP

How do I create a MySQL database connection string in a C# project without utilizing dialog boxes?

NOTE: Apparently, the reason the MySQL connector installation doesn't show up automatically in the Dialog Boxes for adding a data source is because the...Visual 2008 Express Edition...doesn't allow "3rd party integration" within the Visual Studio IDE. So,...
.net c# datasource entity-framework mysql
asked by Ben McCormack

Entity Framework vendors for different databases are shown below.

Which providers are there and your experience using them...I would like to know about all possible native .NET Framework Entity Framework providers that are out there as well as their limitations compared to the default ...LINQ2Entities... (from MS for MS...
.net database entity-framework orm provider
asked by Robert Koritnik

How do I add a view to an Entity Framework model?

When I create a view in database, then I want to add it to EF Model. In the list to add object, I can see and select the view, but nothing happened when try to add it to Model. It is because there is no Key for the view....How to add view to Model?
entity-framework
asked by KentZhou

Get the name of a database table using Entity Framework MetaData.

I'm trying to figure out a way to get the underlying SQL table name for a given entity type. I've experimented around with the MetadataWorkspace queries and while I can get lots of information from the object or the storage space, I can't seem to figure o...
.net database-metadata entity-framework
asked by Rick Strahl

Page 14 of 347
  • ««
  • «
  • …
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • …
  • »
  • »»

Prime Library

Performance

  • Entity Framework Extensions
  • Entity Framework Classic
  • Bulk Operations
  • Dapper Plus

Expression Evaluator

  • C# Eval Expression
  • SQL Eval Function
More Projects...

Related

  • EF Extensions Online Benchmark
  • WIN an EF Extensions license
  • EF6 BatchSaveChanges for only $79
Save your entities 20× faster with EF Extensions
SaveChanges vs BulkSaveChanges

EF Extensions
Try for free now
Get monthly updates by subscribing to our newsletter!
SUBSCRIBE!