What A Rough Day!!

That was yesterday!! It was a very bad one in terms of productivity. We literally spent the whole day trying to access one instance of SQL Server from other system on the network. But in vain. Microsoft does provide a Knowledge Article on what changes to make to enable remote access but even after that we were left high and dry!

My aim was to understand how data flows in a 3-Tier architecture. But without database connectivity, building the DAL itself was impossible. In the end we decided to proceed with local databases instead of Remote access and try and meet some of the fast approaching deadlines.

Today, was a fruitful one! Referring to msdn and my MCTS prep book I was trying to build one small module and that too with the proper architecture. Some of my team-mates were initially averse in building separate layers for Business Logic and Data Access but I pressed and convinced them. For the time being at least.

The best part was after a days work, of the three Unit Test Cases I had written for this module, I was successful in 2 of them at the first shot. And the third case which failed was debugged in no time, thanks to the proper segregation of business logic and data access from the presentation.

The coming days are going to be more exciting as I hope to learn more about Disconnected classes for data access in ADO.NET. Will surely post a few useful tips around the weekend!! Hopefully!

Till then, Happy Programming!

Happy New Year!!

Wishing all a Very Happy New Year!! Though we are already a month into it!!

Well, its been quite a while since I posted anything here. DO NOT think that my inactivity at this blog means that nothing is happening at the tech front! In fact, a lot has been happening and I really haven’t had the time to write things down. Also, the buggers at my company have now blocked all access to blogger. Forget about posting, I can’t even visit this blog anymore from my company to refer to some links and ideas that I had posted here!!

Anyway, this week we have kicked off with development for our project so a lot of exciting times lie ahead. Lots of things to learn and share with you all :) . Also I hope to kick off development of my own trial project in 3 weeks time or so. Lets see where that ends up. I seem to have lost all motivation to work on that idea anymore. i also got a new idea which seems to be fairly simple but attractive. I just hope that it doesn’t end up being another Wild Goose Chase!

Expect some useful posts soon….till then …… Happy Programming!!

About Gathering & Understanding Requirements, and AGILE Development Model

All Software Engineering text books talk about how important it is for a Software Team to understand the requirements that their software will fulfill. So a person who is gathering requirements from the stakeholders needs to really understand what is desired. Requirements gathering is THE most important stage in the SDLC. Yeah, even I was aware that!

But again textual knowledge and practical knowledge are 2 different cups of tea(or coffee if you’re an American reader :P ) I never really understood its importance until I myself was developing software. (okay I was customizing something already built, but then again I was developing features to meet the requirements from a certain POV..) My development was basically to do what I was told to do. Never really thought about the requirements!! But when whatever I was told to do wasn’t impressing the stakeholders, I was puzzled. My senior used to tell me the requirement and then tell me what should I do to achieve it. But since this wasn’t resulting in something which was desired, I was intrigued. The problem wasn’t that I was being communicated incorrect information. Rather I would say it was incomplete information. From the point of view of the functionality required I was told only a part. But later as i discovered, what I was being asked to develop was something that would integrate 2 business process to make one complete process. Also whatever solutions were being suggested by my senior would provide the User with functionality that the Business Process demanded but unfortunately, not what the User demanded. Whatever was being developed initially would never be accepted!

The problem here is that nowadays people define the process flow and the requirements based on that(at least whatever I have come across…I am sure things are not so bad in other companies..) But a very important factor is to understand who are the people who will use the software and what could be the features that they want. Unfortunately even in the age of Orkut, companies are failing to recognize the fact that a person who is exposed to easy to use web applications like Orkut will hardly like to use a web-app with a boring interface like Service Desk. They will use it not because they like it but because they have to. And this in my view is a factor that decreases productivity and which will drive Enterprise Applications in the coming years.

Another important aspect is if the Users are aware of whether the requirements they want is something which they will use. Most of the times that may not be the case and the person gathering requirements should question the user at each and every stage of the requirement gathering. A very good example is what I encountered today. The Web App I will be developing in the coming days has a forum feature where anybody can post questions. However only people who are considered SME’s in that particular area will be allowed to answer the question!! First of all, why shouldn’t I, not being an SME, be allowed to answer. I may know things that the SME might not or I may be able to provide an answer quickly as the SME(s) might be busy with some issues in the production systems. Secondly if the SME is my dear colleague who sits right next to me would I post on a forum or ask directly to him. The forum thing will work if your organization has a large volume of employees. But in this case, I have a hunch that we are building software which will never be used.

Anyway, whatever the case maybe, what I am learning is programming in C# and ASP.NET and hence I am satisfied! Also the AGILE model of development is followed so should be interesting!

More about agile development some other time!! Till then…. Happy Programming!!

The New VWD 2008 Express

I wasn’t aware that its already out! Yes, Visual Studio 2008 Express Editions were available for download from Monday, 19 Nov, 2007 says the news channel on my newly installed Visual Web Developer 2008 Express. Yeah I installed it last night! Still exploring and will post what I like about it, but in the meantime you can check out Scott Mitchell’s review on 4guysfromrolla.

To Install Visual Web Developer 2008 Express, go here

A Little About Databases

One of the huge disadvantages of using Microsoft Products I find is that you tend to do things improperly! Let me share with you something I learnt today.

I have installed the SQL Server 2005 Express Edition as the default database to use with Visual Studio for my projects. Working in an Enterprise Software Services Firm I am aware that you have special roles for a database administrator. The DBA will never share the system admin or db admin login credentials with you. For your application to access the database in a safe manner a new user is generally created for you to use! At least in my limited experience that is what I have come to know!

So for my demo project I decided to create a new user and not use the sa login. I named this user dba. When deciding on what would be the default schema of this user I decided on db_owner to avoid any access issues later on. ( My database knowledge is limited to RDBMS concepts, writing Queries, Sp etc. I have never undergone any training or ventured on my own into what one would call the DBA’s domain). Using this user I created the tables required for my application. The tables created appear as db_owner.assets.

Now I am using the same user to connect from my app to db. I had no issues in visually building the Connection String which I promptly stored in my web.config file. I had no issues in building TableAdapters with simple SELECT statements as well. However, no I decided to graduate to the next level and create my own Stored Procedures. I try to do this Visually once again but I get a failure message saying the schema dba does not exist or does not have sufficient permissions. OOPS!!

How is that possible? I made dba the db_owner. I check and surely dba still is db_owner. I wonder what could be wrong. Maybe I should try and create the stored procedure from Management Studio Express instead of Visual Studio. Fails again with the same message!

I examine the stored procedure to find “CREATE PROCEDURE dba.assets AS …”. Oh! the schema. When dba created the tables they where created as db_owner.assets. So I expanded the nodes in the Management Studio Express and went to schemas to find that indeed no schema named dba existed. So I created a schema named dba as I saw fit and then tried creating the stored procedure. Voila!

Microsoft assumes a lot of things when it Visually creates anything for you. It sure makes things a lot simple and easy to use but can lead to simple errors like this. If only such an error were to creep up in a production environment!!In this case Microsoft should have taken care that the default schema for dba was db_owner.But that is what software is all about I guess; finding new improvements from time to time.

Value & Reference Types in C#

Sometime in Ocotber when I had started to brush up my concepts about C#, there was a serious doubt in my mind. I was confused as to how were arguments passed in C# and what exactly were value and reference types.

Recently I read an article which is the best I have read so far on this topic. Haven’t found anything like that in books also. So if you are confused or just want to revise on the concepts, read this article.

This was really helpful in understanding the concepts which are very important for Certification. I might post some points to remember but you know … posting also consumes quite a lot of time….!!

FYI-ASP.NET Resources

Since I was back from vacation I have been trying to build a momentum in my learnings of C#. The internet is as good a source as any but still I have a habit of buying books, even though I may not finish reading it.Recently , I was just at Crossword and stumbled upon the C# Black Book. Ever since I got into programming i have found a Black book at my side always handy. It doesn’t necessarily give you the complete concept but the practical examples and real code that you get in the book can serve as a good source for reference. And yeah, without thinking much, I bought it.

I was trying to build a simple web app for inventory management. For this I was using the new membership controls that Microsoft have provided you in ASP.NET 2.0. A very good resource to understand this new feature and indeed almost anything regarding ASP.NET is the site 4guysfromrolla. “When you think ASP, think 4guysfromrolla.com” No doubts about that! I am already fan of Scott Mitchell,founder of the site. Go through his articles on membership and you will understand why. He has also written a lot of articles on a whole range of features which I am sure will be very useful. After going through his article, I was able to merge the database schema for membership with my own schema of course resolving issues with help from msdn forums.

He has also written about how to build a 3-tier application on msdn. This was something I had been looking for a while and was ecstatic when I read the article. You can read that here.

A lot of things happening at the professional front as well. Hopefully things will sort out for the good.

The Break

I was on vacation for quite some time now. But good news is I am back and hopefully rejuvenated to get alive and kicking once again! Gotta buck up! Come on!!

About Certifications and More….

Without wasting any time I have begun work on C# and how I can add value to myself. Industry recognized certifications is the way ahead! In case you are unaware about certifications, they are proof of your competence. You may be knowing Java but is there a standard way to test your profiency in the language? Yes there is! Sun Microsystems will test you (for a price of course!) and if you pass the test you will get a certificate from Sun saying that you are a Sun Certified Java Programmer or SCJP as it is popularly known. The test is not a cakewalk by any means, though you wouldnt call it very tough as well. Like any other exam, planned preparation will see you through. Many of my friends have cleared it and some with exceptional scores. And like Sun Microsystems there are a whole range of Companies that provide you with options to get certified in their products. Certifications add value to your resume. Of course there is a lot of difference between certification knowledge and working knowledge. However, a combination of both will really make you the expert in that field. That is why many of the certifications in their “Who should appear for the test?” FAQ tell that the ideal candidate would have worked on the technology for about year or so. However many of us in India take the test even though we have no working knowledge of the particular technology/product. I guess we have been brought up like that.

So much do you have to shell out to appear for the exam? Well that varies from exam to exam but the simple programming ones cost you around $50-100. That is about INR 2000-4000. Not too expensive I would say given the salaries that people are getting these days in the IT sector in India. And if you are already working for a company chances are that your company will refund the amount back to you. So that’s pretty cool!

Thomson Prometric is the most popular vendor offering tests in various certifications across the globe.

So while I am still in the learning phase of C# and the .NET framework, I will also start preparing for the certifications. That is because if I got to have the edge in the market I must get certified. In the course of the next few posts I will be posting articles about things you should know about C# and the .NET framework that might help you in the certification exam. My first target is to clear the 70-536 Application Development Foundation and then the 70-528 Web Client Development after which I would be a MCTS in Web Application Development. Lets see how this turns out! Godspeed!

To know more about Microsoft Certifications, please go here.
To know more about Sun Certifications, please go here.

The Answer

In my previous post I had written about the dilemma I was facing. Well it seems that the dilemma is no more! And the answer is I will be using ASP.NET and Microsoft tools for developing whatever I develop henceforth.

So how did I arrive at such a decision? Firstly, if you have read my previous post, I do have a soft corner for Microsoft Software and Technologies. This is because I have used them before and find it easy to pick up.

Secondly, my work in the new role will revolve around .NET. Hence, the obvious choice seems to be .NET. Through this week I realized that developing a full-blown web-app in any language/technology/platform/framework involves in-depth knowledge. And as I have to work on .NET I might as well use it.

So the decision has been made. Its going to be C# and ASP.NET 2.0 all the way for the next few months.

Also Mr. Bob Tabor’s videos I downloaded from msdn tilted the balance towards .NET and Visual Studio. For more about that visit MSDN Beginner Developer

In the posts to follow this, I will post about things that I learn about .NET, probably about how to get certified and other useful things as well.