Monday, April 18, 2011

Using Bitly’s “+” Links to Peek at Spam

Thanks to the wonderful technology of spam filters, I rarely see spam anymore. Today, however, this gem came through:


It made it through the corporate filters but to Outlook’s credit it *was* flagged as probable spam.

Obviously I didn’t click the link. A bitly link. Hmmm. I use bitly for my twittering and happen to know that if you add a “+” to the end of any bitly or jmp link, you get an awesome stats page like this:


This usefully tells you where the link takes you (the “long link”)—a dating site—so you don’t have to go there to know. It also tells me how many people have actually hit the link and a bit about them. Here are some interesting stats:

  • 190 clicks as of this writing
  • Most hits come for North America
  • Transmitted exclusively (or nearly so) through email

What have I learned? Even though I have no idea how many spam emails it took to get 190 hits, or what (if anything) those 190 clicks earned the sender, I’m disappointed to find at least that many people were curious enough, gullible enough, or foolish enough, to click the link. If the spam problem hadn’t been pretty much solved years ago, I’d be angry at you 190 people for supporting the industry.

Check it out for yourself, or try adding “+” to any jmp/bitly link you come across for some occasionally interesting data (like this one).

Friday, April 15, 2011

Reduce Noise from Responses To Your Outlook Meeting Requests

I give tech talks to my company’s developers about every other month and each time I send out a meeting request to a large group of people. The few days that follow my meeting request are filled with uninteresting responses—RSVPs from those that can/cannot attend. Like this:


Of course I could mark the request as “no response requested” but I really do need to know how many people are planning to attend so I can have enough space/food available.

There’s a setting in Outlook to automatically process meeting requests and such. I don’t want to use that because I’m not sure it works on responses and even if it does, I don’t want to miss the occasional response that’s been manually edited before being sent.

Here’s what I came up with instead:


This is a mail rule catches messages that look like meeting request responses and moves them directly to my archive unless they contain any text in the body. This has been working quite well for months as any boilerplate reply goes straight to my archive while anything with a custom response still shows up in my inbox.

This could almost certainly be improved, e.g.:

  • There’s probably a built-in way of detecting meeting responses besides searching the subject
  • There’s probably a built-in way of detecting if the user has edited the response besides checking the body for any vowel
  • There’s possibly a built-in way to do this whole thing, hiding as an elusive checkbox eight layers deep in the options somewhere

I couldn’t find solutions to those in the five minutes I spent making this hack. If you have a better way of doing this, please share in the comments!

Thursday, April 14, 2011

Speed Matters: How to Talk About It

I spend a lot of time discussing software with all kinds of people who are not software people (that’s why they hire me!). Some things are easy to describe with a mockup or a formula. For example, screens like these:

image  image

Such screens don’t require all that much explanation as the pictures communicate things so well. Let’s look at the second screen—with the table.

Suppose those messages were loaded from a database and the customer wanted new messages to appear automatically (i.e. without clicking refresh). OK, sure—no problem! This comes up all the time and this is the conversation that always occurs (if you get lost, the software guy is the one asking all the questions and the customer is the one giving vague, unhelpful answers):

“How quickly do new messages need to show up?”


“How quickly?”

“Before too long”

“What’s too long?”

“A while.”

“A while…is that an hour? A minute? A second…?”


“Instantly is really hard (i.e. expensive)…how about ten seconds?”


To the customer, “instantly” is a vague term that is approximately equal to his or her attention span. In this case it’s synonymous with 10 seconds.

I think we need a new scale for talking about such things. I present to you:

The Four Degrees of Speed:

  1. Google
  2. Text Message
  3. Email
  4. Everything Else

I. At Google speed, things happen immediately. The feedback cycle is so fast it’s comparable to typing on a keyboard—your actions are reflected on the screen without delay. Some sites work very hard to achieve this speed. Facebook is close, but the only one that is consistently fast as all hell (like Google) is StackOverflow and its network of StackExchange sites. (NB: I originally called this level “instant message speed”, but that’s actually not consistently fast enough to earn the top spot.)

It’s important to note that many people who have underpowered, spyware-infested PCs never reach this speed. These people usually hate computers because all they know are bad, slow computers. To them, launching a picture from their local hard drive takes 15 seconds, which brings us to level 2: text message speed.

II. Text Message speed is anything that takes about 10-20 seconds. If you text someone, you know you’ve got at least 30 seconds before you hear back. I think this is the level that most people expect “real-time” applications to operate in.

III. Email speed is anything that takes a minute or two. This is long enough that you might take a break from whatever you’re doing instead of hitting “refresh” a million times. It’s also the most inconsistent—no one’s all that surprised when an email that usually arrives promptly takes an hour or more to show up.

IV. Finally, there’s everything else speed. This includes daily builds or overnight batch jobs. These are things like newsletters that go out once a day or physical things you put in mailboxes. It could also be a large file download. If it takes more than a few minutes, it might as well take a few hours or days.


This has a lovely logarithmic quality about it, doesn’t it?

If it’s not already obvious, the reason it’s so important that everyone be at the same level in conversation is that the cost of speed is substantial, especially at level one. If being crazy fast was easy, everyone would do it.

Weather in the Midwest vs. A Typical Shower Faucet

It’s been said that if it weren’t for the weather, we’d never have anything to talk about.

This winter was the longest in recorded history (by my account). But suddenly last week it warmed up, which was great. Except, like fools, we opened up all out windows and thereby turned our house into a humid rain forest. Before long it’ll be too hot and clammy to do much outdoors during the day.

I know it’s heresy to complain about nice weather so close to winter, sorry. We have this awful thing called humidity which makes our weather a lot like this:


The winters are long and cold as a bunch of four letter words chained together, the summers are short and blistering, and spring and fall are absolutely wonderful, but terribly short.

Actually, it rains pretty much all of spring. Damn.

Monday, April 11, 2011

Renaming a SQL Server Database

If a search brought you here, chance are that you can’t rename your database because SQL Server threw up an error about it being locked or active. This makes sense—obviously you can’t rename it if it’s being used by another user or application. But what if you want to rename it anyway?

Here’s how:

  1. Take the database into single-user mode (i.e. you)
  2. Rename it
  3. Return the database back to multi-user mode

This script does just that for SQL Server 2000:

EXEC sp_renamedb 'orig_db_name', 'new_db_name'

SQL Server 2005+ should use this slightly different version:

ALTER DATABASE orig_db_name MODIFY NAME = new_db_name

If you want to rename the actual files on disk, too, this article does a fantastic job with that topic.

If you’re curious what ROLLBACK IMMEDIATE does, this is a great explanation. In short, it rolls back other transactions if they are blocking the desired operation. Without this statement, the ALTER DATABASE command may take as long as forever to run.