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)

22 results in tag: entity-framework-4

How can I use entity framework to query the database server for the current datetime?

I have an entity with a ModifiedDateTime property which I want to be updated with the current datetime from the database instead of the "application" server executing the application....Every time I want to update or add a person to my datebase on SQL Ser...
entity-framework entity-framework-4 entity-framework-6
asked by Levelbit

Check for any modifications that need to be saved.

Is there a way to find out whether there are unsaved changes in my entity context, in the Entity Framework?
entity-framework entity-framework-4 entity-framework-5 entity-framework-6
asked by Palantir

With EF 4.1 Fluent Code First, you may inherit tables per type.

I have a pretty straight forward set of database tables, like:...Vehicle Id RegNo Car Id (FK of Vehicle.Id) OtherStuff Bike Id (FK of Vehicle.Id) MoreStuff ...My class model is as you'd expect: with Vehicle being an abstract class, and then Car an...
entity-framework entity-framework-4 entity-framework-4.1 entity-framework-6 table-per-type
asked by nbevans

Upgrade EF 4 EDMX to EF 6

My application is using a database first EDMX in EF 4. I would like to upgrade everything to EF 6. After getting EF 6 with NuGet I had to make a lot of changes to my classes that are using my EF model, because namespaces have been changed in EF 6. Then I ...
entity-framework entity-framework-4 entity-framework-6
asked by SolarX

Upgrade Entity Framework 4.0 to 6.0 not working

net MVC 2 to asp.net MVC 4 without any problem....And then, I tried to upgrade entity framework 4.0 to entity framework 6....The result is not good. I have about 15000 error.... I have this error appear several times...The type or namespace name 'ComplexO...
entity-framework-4 entity-framework-6
asked by Jean-Francois

Entity framework manually deleted tables cant be generated from EF migration

I have created migration and created the database and the tables . For example the tables are ...A B C D E... . Now again I have changed some part of code and ran ...update-database... command . Everything went smooth and nice and the tables showed the co...
ef-migrations entity-framework-4 entity-framework-5 entity-framework-6
asked by Joy

Two foreign keys with same Navigation Property?

I am new to Entity Framework so I don't know much about it. Currently I am working on My College Project, in that Project I came across a problem where I have two foreign keys refers to the Same column in another table. how can I handle this situation. ..
c# entity-framework entity-framework-4 entity-framework-6 orm
asked by Ankit Agrawal

Upgrade to EF 6.1.1 makes effect of [NotMapped] disappear

I have upgraded from EF 4.3.1 to 6.1.1 and now it seems like the annotation [NotMapped] is useless. Yes, i have change to correct assembly and everything looks fine on compilation....Everywhere where [NotMapped] is present the property is handled as a dom...
asp.net-mvc c# entity-framework-4 entity-framework-6
asked by Gruffalon

ObjectStateManager vs Entry().State

What is the difference between this two and which is preferred? using change object state or ...Entry().state...db.ObjectStateManager.ChangeObjectState(employeeFromDB, EntityState.Modified) ...vs...context.Entry(employeeFromDB).State = EnitityState.Modifi...
entity-framework entity-framework-4 entity-framework-6
asked by myfinite

how to insert parent child while doing entityframework.bulkinsert?

I am using Entityframework 6, I am trying to insert a parent-child kind of data in the database. I am using Entityframework.BulkInsert to insert data. I have ...autoIncrement int primary key... in all the tables...My object is as follows :... var paren...
entity entity-framework entity-framework-4 entity-framework-5 entity-framework-6
asked by user3825003

Entity Framework get user from contex in saveChanges

i have two projects in my solution, UI as mvc and class project for entitiy model code first. I have severall entities in my model but now I need to extend them by new audit fields where I need to save who changed entity. I added new interface...public i...
c# entity-framework entity-framework-4 entity-framework-5 entity-framework-6
asked by kosnkov

How can I permanently fix the "EdmFunctionAttribute is obsolete" warning, which occurs after upgrading to EF6?

I am getting the warning ..."EdmFunctionAttribute is obsolete"... after I have ...upgraded a ...database first project... from EF4 to EF 6.1.3...:...'System.Data.Entity.Core.Objects.DataClasses.EdmFunctionAttribute' is obsolete: 'This attribute has been...
c# entity-framework-4 entity-framework-6 migration visual-studio
asked by Matt

How to pass null values into stored procedure via Entity Framework?

I am using an ASP.NET MVC 4 application with Entity Framework....I want to pass null values conditionally, let's say if pass value into ...DeptID... then it should list of values for only passed ...DeptID..., and if pass ...DeptID = NULL... then it should...
asp.net-mvc-4 entity-framework entity-framework-4 entity-framework-6 sql-server
asked by skiskd

Entity Framework (EF6) + MySql Database First Model Many to Many Relationship Wrong Query Generation

I have a project which has an existing database structure and data. Currently project is running on PHP + MySQL and I'm trying to switch from PHP to C# EF 6.0 + MySQL Database first approach....I have installed NuGet Packages (EF 6.0 and MySQL.Data, MySQL...
c# ef-database-first entity-framework-4 entity-framework-6 mysql
asked by Cihan Uygun

Error occured while Entity Framework generating model

I'm having very few tables in my edmx (not more than 20)...I'm having big list of stored procedures (may be more than 1k) in my edmx....EF version 5.0...Whenever I try to add/update model from DB it always throw this error, can any one help me out with th...
asp.net-mvc-5 entity-framework entity-framework-4 entity-framework-5 entity-framework-6
asked by Mox Shah

An exception of type 'System.Data.Entity.Core.EntityException' occurred in EntityFramework.SqlServer.dll but was not handled in user code

I am new to ASP.NET MVC, I am facing this exception, the connection string looks perfect but still, the exception is raised, appreciate if anyone give me why is happening....Thank you guys...Model 1...namespace MVCTwice.Models { public class StudentCo...
asp.net-mvc asp.net-mvc-4 entity-framework entity-framework-4 entity-framework-6
asked by Alexander Zaldostanov

Entity framework- EF Code First Select foreign key

Model:...public class Address { [Key] public long AddressId { get; set; } public string Street { get; set; } public string Town { get; set; } public string State { get; set; } public string Country { get; set; } } public class ...
asp.net-mvc-5.2 entity-framework entity-framework-4 entity-framework-5 entity-framework-6
asked by jena malone

How do I get the Id of a user given the email address in ASP.NET MVC Entity Framework

I have user information in my database. I wish to get the ID of a user given the email address. To get this in sql you would write the following query code: ...SELECT Id FROM TableName WHERE email_address = "xyz@somename.com"; ...How do I write this using...
asp.net-mvc-4 entity-framework-4 entity-framework-6
asked by Guzzyman

EntityFramework: Database.CurrentTransaction becomes null when exception occurs

Today I faced strange issue with Entity Framework. Consider following class:...public partial class Entities { ... public void DocumentUpdateForSync(string userLogin, IEntrySync document) { var timeEntry = document as Domain.Documents.TimeEntry; ...
c# entity-framework entity-framework-4 entity-framework-6 orm
asked by Sergey

Update Record by using ajax in Entity Framework MVC

I am beginner and trying to update my record by using ...Ajax call... in ...Entity Framework MVC.... I am getting ...idtoSearch... successfully but not getting ...std.FirstName... and ...std.LastName... at controller side. As you can see in my code here..
ajax asp.net-ajax asp.net-mvc entity-framework-4 entity-framework-6
asked by nabia saroosh

Page 1 of 2
  • 1
  • 2
  • »

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!