¡@

Home 

c# Programming Glossary: isdeleted

Can AutoFixture execute a delegate at object creation time?

http://stackoverflow.com/questions/10032535/can-autofixture-execute-a-delegate-at-object-creation-time

suppose I have a method that customizes a User because its IsDeleted property always has to be false for a certain set of tests public.. int Id get set public string Name get set public bool IsDeleted get set public static ObjectBuilder User BuildUser this Fixture.. BuildUser this Fixture f return f.Build User .With u u.IsDeleted false I hand an ObjectBuilder back to the test so it can further..

Soft Delete Entity Framework Code First

http://stackoverflow.com/questions/12698793/soft-delete-entity-framework-code-first

to mark itself as a soft delete In this case it just sets IsDeleted to true My question is how can I make it such that when I retrieve.. such that when I retrieve the object it ignores any with IsDeleted So if I said _db.Users.FirstOrDefault UserId id if that user.. I said _db.Users.FirstOrDefault UserId id if that user had IsDeleted true it would ignore it. Essentially I want to filter Note I..

EF 5 Conditional Mapping

http://stackoverflow.com/questions/19246067/ef-5-conditional-mapping

done like this modelBuilder.Entity Foo .Map m m.Requires IsDeleted .HasValue false This makes it invisible to the context and therefore.. Database.ExecuteSqlCommand String.Format UPDATE 0 SET IsDeleted 1 WHERE ID @id tableName new SqlParameter id e.ID Marking it.. a day ago in the same table get return DELETE FROM 0 WHERE IsDeleted 1 AND DATEADD DAY 1 DeletedAt GETUTCDATE UPDATE 0 SET IsDeleted..