I just found a web site that I had been looking for for years now: Musipedia lets you search for a song by whistling the tune:
You have to go through a bit of configuration to allow your Java plugin to record the sound of your whistling.
Basically, on Windows XP/2000, you have to save a file called "c:Documents and Setting.java.policy" with these contents:
permission javax.sound.sampled.AudioPermission "record";
After that, you will be able to whistle or sing a tune, then search for it.
I tried out whistling part of Vivaldi's "Concerto in D minor for two mandolins". It came back as a possible finding, along with (among others) Lennon & McCartney's "No Reply".
It works by using something called The Parsons Code for musical contours. Basically, it tracks relative note values by listing if the melody when Up, Down or Repeated, as U, D, or R. So the Parsons Code that I whistled into the search engine was "*UDDDDDRR", which is also the pattern for part of "No Reply".