ef-code-first
Deleting rows from a collection using ef code first
I have the following domain model: public class Campaign { public virtual long Id { get; set; } public virtual string Name { get; set; }[详细]
2023-04-11 17:16 分类:问答EF Code-First - Mapping stored procedures
I\'m trying to implement nested sets in my database model. To make it easy to use I would like to create stored procedures for insert/update/delete operations on my tree nodes to keep my tree in a val[详细]
2023-04-11 13:02 分类:问答public T Add<T>(T entity) | I have three types of collections, how to know which to add the entity?
I have an interface IRepository to abstract my repository: Fake repository public class Repository : IRepository[详细]
2023-04-11 12:24 分类:问答Adding a property for the count of associated entities in Entity Framework Code First
I\'m using Code First to write my data lay开发者_StackOverflower, then transmitting to a Silverlight front end using RIA services.Since I have to serialize everything, I would like to get some additio[详细]
2023-04-11 11:11 分类:问答DbSet.Attach, what exactly does it do?
Follow the methods below: public class User { [Key] public Guid Id { get; set; } public string Name { get; set; }[详细]
2023-04-11 10:02 分类:问答Why foreign key is added to my table
I have a model: public class QuestionRevision { [Key] public int Id { get; set; } public int IdEditor { get; set; }[详细]
2023-04-11 09:57 分类:问答EF Code First - {"CREATE DATABASE permission denied in database 'master'."}
I just want to quickly spin up the default database in my development environment. How开发者_如何学Go is the easiest way to get around this problem?I once faced this problem and resolved it. The key[详细]
2023-04-11 07:48 分类:问答Upgrading to MvcMiniProfiler 1.9 from 1.7 .NET MVC3 and EF Code First
Today I\'ve dropped back into a project that I haven\'t been working with f开发者_运维问答or the past month or so. I had this project configured using MiniProfiler 1.7 and all was well in the world. I[详细]
2023-04-11 05:02 分类:问答How to configure EF Code First to not map a specific type?
I was getting the following error when runing such this code: var dbContext = new MyDbContext(); var list = dbContext.Set<TEntity>().ToList();[详细]
2023-04-11 01:27 分类:问答RequiredAttribute on private fields
I have a entity public class Avatar { [Key] public int Id { get; set; } [Required] private string _linkInString { get; set; }[详细]
2023-04-11 01:20 分类:问答
加载中,请稍侯......