May 2009 - Posts
Having something enumerable is the gateway to all LINQ’s loveliness. But sometimes you have just one object. So how do you make that enumerable? var people = new Person[] {person}; Not exactly hard huh? In fact you can simplify this even more, you can
Read More...
Not long ago I wrote a ‘sneak peek’ for our new Pluralization features on the ADO.NET team blog. There is a more indepth post coming soon… But it seems the community is starting to do our education for us, and beating us (or should I say me) to the punch!
Read More...
This is 21st post in my ongoing series of Entity Framework Tips , and the first that is specific to EF 4.0. Entity Framework 4.0 Beta 1 As you’ve probably heard VS 2010 Beta 1 is now available to subscribers which means some of you can get your hands
Read More...
This is 20th post in my ongoing series of Entity Framework Tips . Fixed Length Field Padding: If you have an fixed length column in the database, for example something like NCHAR(10) when you do an insert, padding happens automatically. So for example
Read More...
This is the 19th post in my ongoing series of Entity Framework Tips . Background: If you have a table with a timestamp column, and you reverse engineer an Entity from that table, you will end up with a Binary property in your entity (in my example called
Read More...
One of the most common questions we get is how long should an ObjectContext should live. Options often cited include one per: Function Form Thread Application Plenty of people are asking these types of questions, case in point here is a question on Stackflow
Read More...
Background: In Tip 13 - How to Attach the easy way I showed you how to ‘establish’ the EntitySet for a particular CLR Type so you could Attach it. But in all the tips so far the same basic pattern is used: Attach the original version of the Entity Modify
Read More...
How did I miss this ? Jonathan Carter (aka LostInTangent ) has done a Channel 9 video on our upcoming Model First experience. Model first was announced a while back here .
Read More...
Background: In order to be an EF power user today you really need to be familiar with EntitySets . For example you need to understand EntitySets in order to use AttachTo(…) or create EntityKeys . In most cases there is only one possible EntitySet for
Read More...