Development With A Dot

Blog on development in general, and specifically on .NET

Sponsors

News

My Friends

My Links

Permanent Posts

Portuguese Communities

Browse by Tags

All Tags » O/RM (RSS)
Entity Framework Code First Fluent Validation
Back to Entity Framework Code First (EFCF) validation. On my previous post I mentioned that EFCF did not support fluent validation. While this is true, it isn’t too hard to implement one such mechanism, which is exactly why I am writing this! I will be...
Entity Framework Code First Validation
Introduction Most persistence frameworks implement some kind of custom validation of entities before they are sent to the database. By custom I mean something more than just “is not null”, “has XX characters”, etc. This typically includes individual properties...
Filter Collections Automatically With Entity Framework Code First
Introduction In some O/RMs, it is possible to specify automatic filters for entity collections such as one-to-many or many-to-many. These are applied automatically whenever these collections are being populated. Entity Framework does not offer one such...
Querying Entity Framework Code First Inheritance
This is a short post to complement my previous one on Entity Framework Code First Inheritance : how to query for a specific class. The options are: From the DbContext collection: 1: IEnumerable<DerivedA> derived = ctx.Bases.OfType<DerivedA>...
Entity Framework Code First Inheritance
Introduction Another post for self reference, this time, how to map inheritance strategies with Entity Framework Code First. Single Table Inheritance / Table Per Class Hierarchy First, the default strategy: one table for all classes in the hierarchy....
Entity Framework Code First Relations
Introduction This post is more for self-reference than anything else. Basically, I tend to forget some options for mapping relations with Entity Framework Code First, so I wrote this. If in doing so it helps someone, even better! One-to-Many First, the...
NHibernate Pitfalls: Collections of Elements and Inverse
This is part of a series of posts about NHibernate Pitfalls. See the entire collection here . When mapping a collection of elements, this collection should not be marked as inverse . This is a different behavior from many to many or one to many, and it...
NHibernate Pitfalls: DateTime Type Loses Milliseconds
This is part of a series of posts about NHibernate Pitfalls. See the entire collection here . By default, when you have a mapped DateTime property on an entity, if you don’t specify any type, NHibernate will use the NHibernate.Type.DateTimeType type....
NHibernate Pitfalls: Take and Where Order in LINQ Queries
This is part of a series of posts about NHibernate Pitfalls. See the entire collection here . Starting with NHibernate 3.3.3, the order by which the Take and Where operators are placed on a LINQ query matters, whereas before this version, it didn’t. This...
Custom LINQ Extensions for NHibernate
With extensibility virtually everywhere, NHibernate is nice to work with! Consider, for example, a need to call a database-specific function in a LINQ query – a typical request. In SQL Server there is the SOUNDEX function, which can be used to generate...
More Posts Next page »