July 25th, 2008

How to rename a column in Sybase ASE

Today I needed to rename a column in a Sybase ASE 12.5.1 database, and couldn’t seem to find the right syntax. My first few search results gave me syntax that was not actually relevant for my database. Two different pages led me to believe that some variation of this might work:

ALTER TABLE [table_name] RENAME [old_column_name] TO [new_column_name]

But that did not work for me. Upon closer inspection, I noticed that those two pages were for Sybase ASA, not ASE. I refined my search terms a bit, and found this:

sp_rename ‘[table_name].[old_column_name]’,'[new_column_name]’

Thanks to Rob Verschoor for posting this on dbforums.com!

June 12th, 2008

Petco Survey fast track

You know those surveys that print out at the bottom of your Petco receipts sometimes? You just have to call the toll-free number, enter the Survey Pass Code from your receipt, and answer some questions through an automated system, then you get a validation code for a $2-off coupon.

Usually, I put thought into it, and try to answer the questions honestly, based on my experience. Depending on your answers to each question, the number of questions can vary. If you answer anything negatively, they want to know more about what the problems were, which leads to more questions, including some where you speak and it records your comments.

When I have any complaints about a particular visit, I voice them, and that’s fine. This is what the survey is for, and I like to think that my negative comments cause the store to be held accountable.

Sometimes, I just don’t have time, but still want my $2 coupon. So, here’s how to get through these surveys quickly and easily:

  1. Press 1 for English
  2. Enter your 13-digit Survey Pass Code (don’t follow with pound sign)
  3. Press 5 (to say your experience was excellent)
  4. Write down the 4-digit validation code on your coupon

That’s it, and it takes less than a minute!

February 18th, 2008

DMV: wait times misleading, vision test confusing

I had to go to the Virginia Department of Motor Vehicles (DMV) last week, for the first time in several years. Their web site is very useful and usable, so I’ve done most of my DMV transactions online in recent years. Things like vehicle registration renewal, change of address, driver’s license renewal, etc. only take a few minutes on the website.

Apparently every other 5-year driver’s license renewal cycle, you have to get a vision screening, though, so you have to go in to a physical DMV location. This year was one of those years, for me.

Before going in, I looked up my local DMV location (Manassas) on their Office Locations page, to see how long the wait time would be. The site shows realtime stats for your closest location and two or three other nearby locations. At 11:41am, the site said 9 minutes and 12 seconds, which seemed reasonable enough.

So, I headed down there. The wait ended up being a bit longer than that–35 minutes or so to get called to a window (just the first of 3 things I had to wait for).

When I got to the window, I had to take my vision test, and apparently I did not understand how to use the simple device they use to perform that:

Stereo Optical Optec 1000 Vision Tester

I was supposed to put my forehead on the pad, look into the machine, and read the first line of letters. But I could not find a “line of letters”! Not a first one, not a second one, none.

I could see a tiny ‘F’, and what I believe was a tiny ‘B’ or something, but depending on how I looked at it, the B was sometimes below the ‘F’, sometimes to the right, and sometimes below and to the right. In any case, these definitely did not constitute a “line of letters”, and I could barely see them.

I tried numerous times to step back, re-set my forehead on the pad, and look into the device, but I kept seeing the same thing. This went on for a minute or two, and I was freaking out by this time, thinking I was going to be unable to renew my license because the machine says I’m blind.

I asked if I could try a vision test machine at a different window, but she said this one should be working. She tried looking into it, to make sure, and she somehow saw lines of letters. She suggested I read the second line instead of the first. I maintained that I could not see any lines of letters, let alone a “first” or “second” line.

Eventually, I bent down and looked into it from a different angle (I looked upwards instead of straight down the barrel of the machine), and saw a whole chart full of large, clear letters. I read the first line, with no trouble at all, and we both breathed a sigh of relief.

In hindsight, it might have helped if she (or I) had angled the machine upwards towards me, since the thing that finally worked for me was bending down AND looking upwards. Not once did she suggest changing the orientation of the machine to fit me, though, and I didn’t know if/how much they actually move, so I never thought to ask.

After the vision test, I paid the renewal fee, then sat down and waited to have a new picture taken. I didn’t ask to get a new picture taken–I kind of liked my old picture. It’s from 8-9 years ago, when my hair was the longest it’s ever been. It was a conversation piece, if nothing else. Here it is, feel free to point and laugh and call me a dirty hippie (notice the Phish t-shirt, too)! I’ll post the new picture eventually, whenever I have a reason to scan my new license.

Dave’s old driver’s license photo

It was about a 10 minute wait to get my picture taken, then another 5 minutes waiting for the new license to be printed. So, all told about 50 minutes of waiting. I’m glad I won’t have to do that again for 10 years.

After I got home, I checked the website again, expecting to see much higher wait times (since I’d just experienced them first-hand). The site did show a longer average wait time: 17 minutes and 32 seconds, but that’s still way less than what I actually sat through.

Average Wait Times at 11:41:50 AM:
Manassas 9 Minutes and 12 Seconds
Actual Wait Time at 12:04 PM:
Manassas About 35 minutes
Average Wait Times at 1:22:05 PM:
Manassas 17 Minutes and 32 Seconds

Summary:

There are 2 main points I hope that I’ve conveyed with this blog entry:

  1. Although the real-time average wait time information on the Virginia DMV website seems pretty cool, and may be useful as a *very* rough indication of how busy they are, there is a huge margin of error. I don’t know what exactly they’re averaging to come up with those numbers, but my actual wait time was at least 3 times as long as the website showed.
  2. When looking into the vision screening device, look upwards a little bit, rather than straight down the barrel of the machine. Otherwise, you’ll look like a moron, and waste time, which means longer wait times for everyone else.

February 2nd, 2008

QUICK TIP: Easier Macaroni and Cheese Preparation

Kraft Macaroni and Cheese Spirals

The directions for preparation on a box of Kraft Macaroni and Cheese Spirals are:

  1. Boil 6 cups water. Stir in Macaroni. Boil 6 to 8 minutes or until tender, stirring occasionally.
  2. Drain. Do Not Rinse. Return to pan.
  3. Add 3 tablespoons spread[/butter] (or 1/2 tablespoon unmelted butter for lower fat preparation), 3 tablespoons 2% milk (or skim milk for lower fat preparation), and Cheese Sauce Mix, mix well. Makes 3 servings.

Here’s a simple trick my wife, Lacey, taught me to make step 3 a little bit easier:

After returning the drained pasta to the pot, turn the stove back on, at its lowest setting. Then, add the butter, which will be much easier to stir in with a little bit of heat melting it. Next, add the milk, and stir that up. At this point, the pasta is coated in butter and milk, which makes the cheese powder stick to it better. I leave the heat on until I’m completely done mixing it all up, which also ensures that the finished Mac and Cheese will actually still be warm by the time you dish it out.


Image and preparation directions taken (slightly cropped/rearranged) from product info on Amazon.com: Kraft Macaroni & Cheese Spiral, 5.5-Ounce Boxes (Pack of 24)

January 19th, 2008

Finally got a shaving brush

shaving brush, shaving cream, Gillette Sensor razor

Ever since I read an article a year or two ago about how to get a better shave, I’ve been wanting to try out some of their tips. I believe that’s when I started shaving in the shower, which I definitely like better than trying to shave at the sink. I’ve had “shaving brush” on my Christmas, birthday, and Father’s Day wish lists, but it just never happened… until this past Christmas (2007). Lacey bought me a shaving brush and shaving cream.

I’m not brave enough or motivated enough to try a different type of razor, at this point, so I’m sticking with either my Gillette Sensor (which I’ve had since Gillette was nice enough to send me a free one for my 18th birthday; nice marketing, Gillette!) or my Schick Quattro. I prefer the Quattro, but the cartridges are more expensive so I only get them occasionally (sale + coupon is always good!). I can usually get a big pack of Sensor cartridges for a less outrageous price, although even those seem pretty darned expensive. I actually tried some generic cartridges last year, which fit Sensor razors, but the difference in quality was quite noticeable. I’ll stick with the name brands.

Anyways, I’ve used the shaving brush + shaving cream 4-5 times, now, and I’m definitely a fan. I’ve been able to get the closest shaves I’ve ever had, with no irritation, and have even been able to get more uses out of a single razor cartridge than I could when I just used regular store-bought mainstream shaving gel (i.e. chemical-rich goo).

If you’ve never tried using a good shaving cream and a badger-hair shaving brush, you don’t know what you’re missing. I’ve always hated shaving, and although the brush+cream didn’t make me actually enjoy shaving, like they have done for some people, they definitely make shaving less annoying.

I’m not sure where the article that I read a couple years ago, that first sparked my curiosity on this subject, but here are a couple that I’ve read since then:

and a couple of pages with links to more shaving-related information/tips/etc.: