Archives for n-Tier Apps - Page 2
Update EDMX model with database changes
Open the EDMX file within Visual Studio – use an Open With command from the right click menu Open With -> Entity Data Model Designer Right click on the designer…
Linqer–Convert SQL statements to LINQ
LINQPad, the most popular LINQ tool out there , does not convert SQL statements into their equivalent LINQ syntax. However, a free tool called Linqer does just that. Linqer takes…
Inheriting an existing Entity Framework Implementation
Several quirks may pop up – the project may not work seamlessly in your local environment. Entity Framework generates a slew of files – most notably its mapping file (with…
Entity Framework–where to put the data folder
In your folder structure, where shoul you put the edmx data folder? As all EDMX files are representations (abstractions) of some relational database, they belong in the Models folder. The…
Hibernating Rhinos – nHibernate Profiler
1. To get started with this powerful profiler, simply install the NuGet package (look for nHibernate Profiler). it places all the required assemblies in your project AND…
nHibernate transactions and rollbacks
Introduction The same rollback considerations that apply to normal SQL transactions also apply to nHibernate transactions. Rollback Scenario Suppose you have two SQL Statements – the first one tries to…
Fluent nHibernate setting database transaction isolation level
Introduction Normally, if you do NOT specify the isolation level for an nHiberante transaction, it will remain undefined. This is bad for many reasons – the primary one being that…
Troubleshooting nHibernate Performance
Introduction nHibernate is still one of the most popular ORM layers in use today. It provides support for collections, advanced querying, caching, statement batching, automatic change tracking for entities and…
nHibernate–manual session flushing
An nHibernate session maintains all changes to the object model. At some point, it needs to synchronize these changes with the database. It can either do these constantly (as and…