2009/07/23
From Tables to Objects
2009/07/09
Brent Ozar - What I want vs what I can afford
Brent Ozar - 10 questions to ask senior DBAs
2009/07/07
Twikini for Windows Mobile
Twikini is a pretty outstanding bit of software for your Windows Mobile device. It has a much sexier UI than my other favorite client, TinyTwitter. It also runs noticeably faster. The UI is more intuitive than Pocketwit.
For most of my Tweeting needs, Twikini more than fits. I still use TinyTwitter for viewing individual timelines but since Twitter has been ignoring the #fixreplies, I see my usage of TinyTwitter falling and Twikini filling that void.
So take a look at that sweet UI and head over to http://www.trinketsoftware.com/Twikini and get a demo version to kick the tires.

2009/01/13
Open letter of recommendation: Arnulfo Wing
Through our many conversations, Arnulfo showed his depth of knowledge of the system. Both within BizTalk and the application that BizTalk supported. He also showed a great desire to help others understand what many look to as a "black box". He was instrumental in extracting the rules, orchestrations, literally every piece of information pertinent to the project out of the BizTalk instances so that development wouldn't have to start on the new rules engine with a blank slate.
Arnulfo also showed genuine interest in what was happening in other parts of the solution. Though BizTalk was his primary responsibility, he was available to assist in troubleshooting, design questions, and ensuring delivery.
Arnulfo has a thirst for knowledge of new technologies and methodologies. I've seen him at many area user groups. Talked to him about local conferences. He is more than "Just BizTalk". Given his ability to grok very complex systems, his excellent people skills, his depth and breath of knowledge, and his client-facing demeanor, I can see Arnulfo being able to fill many positions. These include Developer, Team Lead, and Architect.
Arnulfo's blog is available at http://arnulfowing.blogspot.com/. There you can see some of the experience he has accumulated from Hyper V corrupt drives to setting TFS to run on multiple servers... and of course, there's BizTalk.
2008/10/23
Sprint WinMo Roundup
The first go round I picked up a Samsung ACE (SPH-i325). This was a nice, sleek phone running Windows Mobile 6. Thinner than a pack of playing cards and had an easy-to-use thumbboard. The response on this phone was fast. It had a microSD slot for additional storage. The phone also sported two features that I instantly fell in love with Automatic Speech Recognition and Automatic Profiling. The phone also supported international calling via GSM networks using either the provided or a pre-paid SIM card (something I didn’t use). A pretty good phone for about $100. But the phone did have shortcomings. After playing around with Live Search and Google Maps, the lack of an integrated GPS radio really stood out as a deal breaker, especially after finding no upgrade path to Windows Mobile 6.1.
Round two went to an HTC Mogul (PPC6800). This phone was a brick. But it had a HUGE touch screen and a slide out QWERTY keyboard. It also had the much desired GPS and upgrade possibility to Windows Mobile 6.1. The phone also had a microSD slot. But it was lacking my new loves ASR and Automatic Profiling. Additionally, the ROM seemed a little sluggish. There are plenty of 3rd party ROMS and tools to get an ALMOST automatically switch to vibrate mode during meetings. For nearly $300, I’d want to be ecstatic about my phone. Not permanently searching to find ways to add the functionality that the ACE had.
At this point, you might ask “What’s the big deal with ASR and Auto Profiling?” ASR should be on EVERY phone, PERIOD. ASR is more than the voice recognition on many phones where you have to record a dumb tag (Call Joe Smith Mobile, for example). You then assign the tag to the action you want the voice tag to perform. ASR is so much better. ASR has some built-in actions (Call, Open, Play, etc). So you can put in a new contact (Joe Smith) and then instantly have the ability to speak “Call Joe Smith Mobile” and it just works. No pre-recording; you just speak. Additionally, the Ringer Profiles with Automatic Profiling should be on ANY phone that has calendaring applications. Automatic Profiling puts your phone into vibrate during scheduled meetings. This is especially important if your team has a rule of “your phone rings during meetings; you buy donuts”.
Finally, we come to my current hotness. The HTC Touch Diamond (MP6950) is a true iPhone killer. It’s a thin phone with a big, beautiful touch screen. It has a built-in GPS radio. Comes with Windows Mobile 6.1 pre-loaded and has both ASR and Automatic Profiling. Also the TouchFlo3Dtm UI is frickin sweet. The different touch keyboards available make input easy with stylus or by touch via Compact QWERTY. Additionally, there are accelerometers to determine if the phone is in portrait or landscape orientation. The phone comes with 4GB of internal storage. It is the greatest combination of features I’ve seen in a phone and it is the best phone Sprint has available. So much awesome is packed into this tiny form factor I don’t think I put it down for the first week.
I know that HTC is about to release the Touch Pro with all the goodness of the Touch Diamond with a slide out keyboard headphone jack (the diamond has a dongle for this) and a microSDHC slot for something like 32GB of additional storage. I think I’m good with the Diamond and have had enough of the headaches associated with returning phones for exchange. I don’t think the HTC models can be beat. The Touch Pro is great for those that like the slide out keyboard. The Touch HD is to have a camera to beat anything on the market. But if you can’t wait, you can’t go wrong with the Diamond.
2008/07/16
Got TFS Hate?
2008/07/07
When good coders write bad code.
I ran into a side-effect of this mentality on my latest project. Recently, I was working on optimizing some SQL queries that were running slow. In the middle of plowing through some of the newly added functions I came across one that really seemed to stick out.
In a nutshell, the function was to take a case identifier and return a "hierarchical" start date so that if ActualEndDate exists, return ActualBeginDate. If ApprovedEndDate exists, return ApprovedBeginDate. If CertifiedEndDate exists, return CertifiedBeginDate. If RequestedEndDate exists, return RequestedBeginDate. If all these conditions are false, return NULL.
Here is some sample data:
CaseID | RequestedBegin | RequestedEnd | CertifiedBegin | CertifiedEnd | ApprovedBegin | ApprovedEnd | ActualBegin | ActualEnd |
1 | 7/1/2008 | 7/31/2008 | 7/1/2008 | 7/14/2008 | 7/1/2008 | 7/7/2008 | 7/3/2008 | 7/7/2008 |
2 | 8/1/2008 | 8/30/2008 | 8/3/2008 | 8/30/2008 | 8/4/2008 | 8/30/2008 | 8/10/2008 | NULL |
3 | 9/1/2008 | 9/30/2008 | 9/2/2008 | NULL | 9/3/2008 | NULL | 9/4/2008 | NULL |
And here are the calculated Hierarchical dates
CaseId | HierarchicalDate |
1 | 7/3/2008 |
2 | 8/4/2008 |
3 | 9/1/2008 |
So looking at the function that is used to return the scalar value, I see this:
7 CREATE FUNCTION [dbo].[getHierarchicalDate]
8 (
9 @CaseID bigint
10 )
11 RETURNS datetime
12 AS
13 BEGIN
14
15 declare @HierarchialDate datetime
16 declare @ActualEnd datetime
17 declare @ApprovedEnd datetime
18 declare @CertifiedEnd datetime
19 declare @RequestedEnd datetime
20
21 set @ActualEnd =
22 (select ActualEnd from cases where caseid = @caseID)
23 set @ApprovedEnd =
24 (select ApprovedEnd from cases where caseid = @caseID)
25 set @CertifiedEnd =
26 (select CertifiedEnd from cases where caseid = @caseID)
27 set @RequestedEnd =
28 (select RequestedEnd from cases where caseid = @caseID)
29 if @RequestedEnd is not null
30 if @CertifiedEnd is not null
31 if @ApprovedEnd is not null
32 if @ActualEnd is not null
33 set @HierarchialDate =
34 (select ActualBegin from cases
35 where caseid = @caseID)
36 else
37 set @HierarchialDate =
38 (select ApprovedBegin from cases
39 where caseid = @caseID)
40 else
41 set @HierarchialDate =
42 (select CertifiedBegin from cases
43 where caseid = @caseID)
44 else
45 set @HierarchialDate =
46 (select RequestedBegin from cases
47 where caseid = @caseID)
48
49 RETURN @HierarchialDate
50
51 END
Yup, 8 SELECT statements. And this was written by a developer who has been in architect roles. Someone respected. Someone who should know better. So with a little adjustment, the function become this:
7 CREATE FUNCTION [dbo].[getHierarchicalDate]
8 (
9 @CaseID bigint
10 )
11 RETURNS datetime
12 AS
13 BEGIN
14
15 declare @HierarchialDate datetime
16
17 select @HierarchialDate = CASE
18 WHEN ActualEnd IS NOT NULL and ActualBegin is not null
19 THEN ActualBegin
20 WHEN ApprovedEnd IS NOT NULL and ApprovedBegin is not null
21 THEN ApprovedBegin
22 WHEN CertifiedEnd IS NOT NULL and CertifiedBegin is not null
23 THEN CertifiedBegin
24 WHEN RequestedEnd IS NOT NULL and RequestedBegin is not null
25 THEN RequestedBegin
26 ELSE NULL END
27 from [Cases] where caseid = @CaseID
28
29 RETURN @HierarchialDate
30
31 END
So we're down to one SELECT statement. One table scan. All because nobody took a step back to ask "is there a better way". This is something that seems to prevalent in our industry. Nobody wants to admit they are over their head, that they don't know everything, that someone else might have a better solution. I don't have the answers, so I'd love to hear any feedback.
2008/06/17
Software Development Meme
How old were you when you first started programming?
I'm not sure if it was 3rd or 4th grade that I started coding in BASIC on an Apple IIe for about 3 months. Much of it was minor tweaks to "busy-work" type applications.
I pretty much gave up on coding for quite a while. Games were much more interesting (NES was recently released and I <3 8-bit graphics). During my sophmore year in high school (1995), I caught wind of this "series of tubes" and picked up HTML for a class project. Designing the school's webpage... and using the much loved nested tables and shim images.
I continued web development through college even though I changed majors out of the CS department becuase it was all console UNIX C/C++. The IT degree, yes that's INDUSTRIAL Technology had the VBA and ASP courses. As an added bonus, I got to cut and melt things.
What was your first language?
I really don't want to say BASIC as it was mostly copy from book and tweak parameters. So, I'll go with the safe bet and say HTML.
What languages have you used since youstarted programming?
BASIC, HTML, JavaScript, PASCAL, C, C++, VB/VBA/VBScript, PL/SQL, T-SQL, WiseScript, InstallScript, VB.Net, C#, WinBatch, AJAX. Also, a bit of G-Code and whatever Rockwell Automation PLC's use.
What was your first professional programming gig?
That would be working at Ohio University to earn beer money. I had moved up from help desk to NT administration. This required writing batch files, VBScripts to automate system setup and configuration. Somehow, it also involved creating the department websites.
If you knew then what you know now, would you have started programming?
Actually, I would have started programming earlier. I would have hopped into programming without the time suck of Infrastructure Operations until I "paid my dues".
If there is one thing you learned along the way that you would tell new developers, what would it be?
Be a jack of all trades and a master of (at least) one. You'll need to have a little bit of knowledge in many subjects to be adaptable but find a niche and be the subject matter expert in that area.
What's the most fun you've ever had ... programming?
Somehow, its the projects that are the most annoying at the time that are the most fun in retrospect. But I'd probably have to go with tweaking out TFS with ASMX subscriptions to trigger automated builds, customizations, and deployments. Spinning up a managed instance of MSBuild engine when everyone else is running powershell makes me giddy.
Next up
Greg Bahrey
Arnulfo Wing
Dan Shultz
Alexey Govorine
</meme>