<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en"><title type="html">Coffee, smoke and techilicious burps at 3.47 AM</title><subtitle type="html">Some half baked ideas by Nilotpal about Tao, Zen and the art of converting coffee into code...</subtitle><id>http://weblogs.asp.net/nilotpal/atom.aspx</id><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/default.aspx" /><link rel="self" type="application/atom+xml" href="http://weblogs.asp.net/nilotpal/atom.aspx" /><generator uri="http://communityserver.org" version="3.0.20510.895">Community Server</generator><updated>2009-01-15T19:58:17Z</updated><entry><title>Visual Studio 2008 Unit tests… Error loading *.vsmdi: *.vsmdi</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/09/22/visual-studio-2008-unit-tests-error-loading-vsmdi-vsmdi.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/09/22/visual-studio-2008-unit-tests-error-loading-vsmdi-vsmdi.aspx</id><published>2009-09-22T13:01:38Z</published><updated>2009-09-22T13:01:38Z</updated><content type="html">I got this error. I got no information on the internet as to how to get around it… 3 hours earlier: I wanted to create a sequence diagram from the code I have already written. Visual Studio 2010 comes with the sequence diagram feature. I decided heck why not use it. It creates some really cool sequence diagrams. I opened the same project in Visual Studio 2010, created the sequence diagram, closed the project. Went for a smoke. 30 minutes earlier: My test cases won’t run. the error I get is&amp;#160;...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/09/22/visual-studio-2008-unit-tests-error-loading-vsmdi-vsmdi.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7213946" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>UML 101</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/09/09/uml-101.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/09/09/uml-101.aspx</id><published>2009-09-09T03:13:31Z</published><updated>2009-09-09T03:13:31Z</updated><content type="html">So you need to read the entire UML book in 20 minutes. What do you do? These are the excerpts from the Unified Modeling Language Reference Manual I was reading and thought I could summarize for a quick refresh. &amp;#160; Aggregation and composition: Generalization: Kinds of dependencies: Use case diagram: Kinds of Use Case relationships: Activity Diagram: Sequence diagrams and Activation: Component Diagram: Deployment Diagram: Packages and relationships:...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/09/09/uml-101.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7197120" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Dots instead of spaces in Studio 2008 while running test cases…</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/08/22/dots-instead-of-spaces-in-studio-2008-while-running-test-cases.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/08/22/dots-instead-of-spaces-in-studio-2008-while-running-test-cases.aspx</id><published>2009-08-22T09:51:16Z</published><updated>2009-08-22T09:51:16Z</updated><content type="html">Well I was running my test cases today and suddenly all my white spaces turned into dots. Yes it creeped the heck out of me. First thing I thought was to get rid of that. Went to Tools and Options and couldn’t find the setting that would get rid of the nauseating dots. So I started trying all the shortcut keys. But initially nothing worked. Now Ctrl + R + D happens to be a combination that debugs the tests in context. So I thought the key pattern that enables and disables the visible whitespace feature...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/08/22/dots-instead-of-spaces-in-studio-2008-while-running-test-cases.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7177554" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Left outer join in Entity Framework</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/08/19/left-outer-join-in-entity-framework.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/08/19/left-outer-join-in-entity-framework.aspx</id><published>2009-08-18T20:04:46Z</published><updated>2009-08-18T20:04:46Z</updated><content type="html">This evening I heard someone say that Left Outer Joins are not possible in Entity Framework or perhaps Left Outer Joins are possible, but they bring in all the data and then filter out the right table. I felt an urge to argue, but I resisted. I thought I would investigate before I waste time. I came up with some articles pretty quickly. Left Outer Join in LINQ Left Outer Join using Inverse Navigation Property DefiningQuery Element Left Outer Join in LINQ to SQL LINQ to Entities with Multiple Left...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/08/19/left-outer-join-in-entity-framework.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7172592" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Singleton Vs. Static Class</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/07/30/singleton-vs-static-class.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/07/30/singleton-vs-static-class.aspx</id><published>2009-07-30T04:40:01Z</published><updated>2009-07-30T04:40:01Z</updated><content type="html">Well I was asked this question once. “What is a singleton design pattern and why should I use it? Why not use a static class instead?” And it was quite surprising how it went. I said that Singleton is used when you need to maintain state. Static classes are used when you want to club together a bunch of stateless methods that do something irrespective of which instance calls these methods. Math class is a good example. So he asked me, can I not maintain state in a static class? So I said if you want...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/07/30/singleton-vs-static-class.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7157507" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>To query the local object context</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/07/28/to-query-the-local-object-context.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/07/28/to-query-the-local-object-context.aspx</id><published>2009-07-28T05:48:53Z</published><updated>2009-07-28T05:48:53Z</updated><content type="html">When faced with the dilemma that what if I wanted to insert something and before I actually saved the changes into a persistent storage (database) by calling SaveAllChanges() method on the data context, I wanted to do a select, and also I wanted to make sure that this select is done on the just inserted objects, what should I be doing? Well generally we write a generic method that gets all the records for a generic object. it looks like this: IQueryable &amp;lt;T&amp;gt; result = null ; string type = typeof...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/07/28/to-query-the-local-object-context.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7155644" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Entity Framework, Business Objects and Beyond…</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/07/14/entity-framework-business-objects-and-beyond.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/07/14/entity-framework-business-objects-and-beyond.aspx</id><published>2009-07-14T17:58:50Z</published><updated>2009-07-14T17:58:50Z</updated><content type="html">Back during the RMI days, we used to generate skeleton (henceforth referred to as skel or skels) and stubs for all long range service communications… Yes… WCF has its roots there and perhaps further into the past…! Details available here . Looking at it from an architectural perspective, the data contracts were designed in such a way that the changes are minimal because every change in the stub would have to trickle down all the way to the client. We have come a long now and Service Oriented Architecture...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/07/14/entity-framework-business-objects-and-beyond.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7147348" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Does not have a valid owner</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/05/30/does-not-have-a-valid-owner.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/05/30/does-not-have-a-valid-owner.aspx</id><published>2009-05-30T07:27:19Z</published><updated>2009-05-30T07:27:19Z</updated><content type="html">“Database diagram support objects cannot be installed because this database does not have a valid owner. To continue, first use the Files page of the Database Properties dialog box or the ALTER AUTHORIZATION statement to set the database owner to a valid login, then add the database diagram support objects” You are sitting at home, working on your work laptop, you have a deadline to meet, give an entity relationship diagram for your technical specification document for the module you are working...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/05/30/does-not-have-a-valid-owner.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7102589" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Xsd to Database</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/05/28/xsd-to-database.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/05/28/xsd-to-database.aspx</id><published>2009-05-28T14:03:32Z</published><updated>2009-05-28T14:03:32Z</updated><content type="html">There are times when you have to work with XML. Yes those dreadful times. Specially the times when you get data as XML. And not just master data you sometimes get transactional data in XML. Think about it. How much worse can it get if you had to work with transactional data, and sync it with the database? I am working on something in that direction. Although I haven’t finalized the approach yet, but it would involve creating an xsd, converting the xsd into datasets and then moving the data into the...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/05/28/xsd-to-database.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7100310" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Your user profile was not loaded correctly! You have been logged on with a temporary profile.</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/04/22/your-user-profile-was-not-loaded-correctly-you-have-been-logged-on-with-a-temporary-profile.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/04/22/your-user-profile-was-not-loaded-correctly-you-have-been-logged-on-with-a-temporary-profile.aspx</id><published>2009-04-22T06:19:05Z</published><updated>2009-04-22T06:19:05Z</updated><content type="html">This is not a problem that I feel you would encounter on a regular basis. I think I had a unique problem because of which I encountered this one. When you install an operating system it allows you to create a profile. Now I installed the machine at home. Which means I was not on the corpnet of Microsoft which means I could not log on to the domain. So when I created a profile named after my alias, it was considered as a local profile and not a domain profile. And a folder was created under “C:\Users...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/04/22/your-user-profile-was-not-loaded-correctly-you-have-been-logged-on-with-a-temporary-profile.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7055471" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Function Point Analysis (FPA) Glossary</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/04/08/function-point-analysis-fpa-glossary.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/04/08/function-point-analysis-fpa-glossary.aspx</id><published>2009-04-08T13:00:55Z</published><updated>2009-04-08T13:00:55Z</updated><content type="html">Internal Logical File (ILF): An internal logical file (ILF) is a user identifiable group of logically related data or control information maintained within the boundary of the application. The primary intent of an ILF is to hold data maintained through one or more elementary processes of the application being counted. External Interface File (EIF): An external interface file (EIF) is a user identifiable group of logically related data or control information referenced by the application, but maintained...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/04/08/function-point-analysis-fpa-glossary.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7035521" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Update an entity in Repository Pattern</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/03/17/update-an-entity-in-repository-pattern.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/03/17/update-an-entity-in-repository-pattern.aspx</id><published>2009-03-17T13:08:19Z</published><updated>2009-03-17T13:08:19Z</updated><content type="html">Look around the web. You will find no Update method in the repository patterns for entity framework implementations published. There are different flavors of retrieves, mark for insertions an deletions but no update implementation. And curiously this is the most painful. There are 2 options that you have. But to explain both, I will start off with the repository design. We can get into a discussion about the pattern in case anyone is interested, all you have to do is instigate me by posting a comment...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/03/17/update-an-entity-in-repository-pattern.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6970233" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Repository Pattern – The purpose</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/03/17/repository-pattern-the-purpose.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/03/17/repository-pattern-the-purpose.aspx</id><published>2009-03-17T00:33:07Z</published><updated>2009-03-17T00:33:07Z</updated><content type="html">We decided to implement the repository pattern for the Entity Framework Implementation in our project. So last couple of weeks people have been asking me why the repository pattern is required. I mean what is it that this pattern does besides giving a layer of abstraction, and providing the CRUD methods, which are also available in C# as a language feature (LINQ). The answer is given aptly by Martin Fowler as, “A system with a complex domain model often benefits from a layer, such as the one provided...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/03/17/repository-pattern-the-purpose.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6968611" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>Are you Eager? Or are you Lazy? Or are you both on a case to case basis...??</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/01/28/are-you-eager-or-are-you-lazy-or-are-you-both-on-a-case-to-case-basis.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/01/28/are-you-eager-or-are-you-lazy-or-are-you-both-on-a-case-to-case-basis.aspx</id><published>2009-01-28T15:37:00Z</published><updated>2009-01-28T15:37:00Z</updated><content type="html">Entity Framework, Eager Loading and Lazy Loading, my own 2 cents. For those new to Entity Framework, we are talking about the patterns that you can use to load related objects. The strategy by which you would load entity objects that are related to the one in question. There is a beautiful resource that mentions it all. I do not think there is any elaboration required in that matter. But this is not the meat of the matter. How do you design an application that uses Entity Framework as a data access...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/01/28/are-you-eager-or-are-you-lazy-or-are-you-both-on-a-case-to-case-basis.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6866462" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry><entry><title>StyleCop and Good Code</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/nilotpal/archive/2009/01/15/stylecop-and-good-code.aspx" /><id>http://weblogs.asp.net/nilotpal/archive/2009/01/15/stylecop-and-good-code.aspx</id><published>2009-01-15T14:58:17Z</published><updated>2009-01-15T14:58:17Z</updated><content type="html">So you are serious about your code quality huh... well StyleCop is a fantastic tool to ensure that. The best part is, it integrates with Studio 2008. It is simple. Go to This Location , click on downloads and download the latest version of StyleCop. As of now it is the version 4.3 Install StyleCop. It asks you information about integration. Let it integrate with Studio for the moment. Fire up Visual Studio Click on Tools and say Run StyleCop and look at the 1001 warnings that StyleCop gives. Now...(&lt;a href="http://weblogs.asp.net/nilotpal/archive/2009/01/15/stylecop-and-good-code.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6836242" width="1" height="1"&gt;</content><author><name>Nilotpal</name><uri>http://weblogs.asp.net/members/Nilotpal.aspx</uri></author></entry></feed>