Every object in SQL Server database has an Object Id which is used extensively by SQL Server for most operations. There are times when we would like to know what the object ID is for a particular object. In this example I will show you two ways to retrieve Object Id. My examples will retrieve [...]
In this walkthrough I will show you how to use Red Gate SQL Data Generator to generate test data for a database. While writing software which interacts with a database developers often write scripts to insert some data. Usually this data is not big enough to find performance bottlenecks and/or issues with presenting data on [...]
Ok, so you’ve seen Windows Presentation Foundation (WPF) and you thought the technology looked interesting. You know your applications are starting to look dated, you understand WPF has matured, now in its 3rd release; but life gets in the way and you haven’t had the chance to get down and dirty with it yet. So [...]
This script returns all default constraints on a table in a SQL Server 2008 database. It gives me the name and definition of the constraints on Person.Address table in Adventure Works database. You can substitute the table name with any other table to get the constraints for that table.
SELECT [name], [definition] FROM sys.default_constraints WHERE [...]
In this post I will document my experience of installing Oracle SOA Suite on Windows XP. No I am not switching and I’m still a Microsoft developer by heart. But I do feel that for me to improve my craft I must also understand how things are done in other camps such as Oracle, SUN, [...]
.NET Framework provides classes which give information about the machine on which code is executed. One Such class is System.Environment which gives us things like Machine Name, OS Version and much more. I recently had a requirement to programmatically detect the number of Processors on a machine. I thought this was a simple enough task. [...]
This snippet shows you how to get information about all CD / DVD drives on your machine using WMI and C#. To run the code you need to add reference to System.Management.
ManagementObjectSearcher mgmtObjects = new ManagementObjectSearcher("Select * from Win32_CDROMDrive"); foreach (var item in mgmtObjects.Get()) { Console.WriteLine("Drive Letter – \t" + item["Drive"]); Console.WriteLine("Name – \t" [...]
This query returns the last row from Sales.Customer table in Adventure Works database. I am using LINQPad to write and execute my query.
(from c in Customers select c) .OrderByDescending(x=> x.CustomerID).First()
Here is the result as displayed in LINQPad
Microsoft Thrive is a clever demonstration of how Silverlight can be used for a public facing website. Other than being a showcase for Silverlight the site also has some valuable content for career development, desktop optimization, cost savings and compliance & governance among others.
The most fun is a game called Are [...]
Windows Live Writer which IMO is the best software for blog posting has been missing a desirable feature. i.e. to backup posts, pages, settings etc. Today I found about Windows Live Writer Backup application on CodePlex. This little application will backup your posts and blog settings. The application is a RC at this stage.
[...]
It feels good when you find a hidden gem on www. Through a link trail which I cannot remember now I somehow landed up on SQL Server 2008 Jumpstart site. Here you can access training material which is categorised into four tracks.
Database Infrastructure Track Business Intelligence Track Developer Track Application Compatibility & Upgrade [...]
This one always gets me off guard so I’m posting this here for more than anything else to remind me. The issue occurs when you configure your MOSS environment which is normally done after installing MOSS. The issue is that while inserting sample data the wizard throws an error which says “Failed to create sample [...]






