What's Wrong With This Code? (#29)

Posted by: K. Scott Allen, on 02 Apr 2012 | View original | Bookmarked: 0 time(s)

Here is some code similar to other code I've seen that has a severe bug. The Entity Framework model configuration is setup to allow optimistic concurrency checks via a movie's Version property. public class Movie { public virtual int ID { get; set; } public virtual string Title { get; set; } public byte[] Version { get; set; } } public class MovieDB : DbContext { public DbSet<Movie> Movies { get; set; } protected override void OnModelCreating( DbModelBuilder...

Category: ASP.NET | Other Posts: View all posts by this blogger | Report as irrelevant | View bloggers stats | Views: 382 | Hits: 23

News Categories

.NET | Agile | Ajax | Architecture | ASP.NET | BizTalk | C# | Certification | Data | DataGrid | DataSet | Debugger | DotNetNuke | Events | GridView | IIS | Indigo | JavaScript | Mobile | Mono | Patterns and Practices | Performance | Podcast | Refactor | Regex | Security | Sharepoint | Silverlight | Smart Client Applications | Software | SQL | VB.NET | Visual Studio | W3 | WCF | WinFx | WPF | WSE | XAML | XLinq | XML | XSD