TV overscans and CD soundtracks

What do overscans and soundtracks have to do with each other? Not a thing, really. But, they are two good things that happened to me on Sunday.

The first one was a bug that I’ve been having with my PVR ever since day one, and it’s been slightly annoying. Basically, the picture on my TV was slighly bowed in on the sides on the top half. Not too bad, but it bothered me because I’m so visually picky. Well, the nvidia module has some settings for X you can put in there (TVOverscan) which I’d played with before, but never enough, I suppose. What I did before was set the variable to “1.0” which, according to the documentation, means to overscan as much as possible. I figured that would stretch the picture and fill in those blank gaps, but it didn’t. Turns out the only numbers that worked were between 0.5 and 1.0. I think I eventually ended up with 0.7, and it looks absolutely fabulous. Of course, now I’m *missing* some of the picture because it’s getting pushed slightly off the screen, but its still much much better.

The second great thing that happened to me yesterday is I won an auction on ebay. That isn’t too exciting in itself, but the fact is that I netted a soundtrack that I’ve been trying to find for years. It’s been out of print and it’s extremely hard to find — so hard, in fact, that this was the first time in as many years as I can recall that I’ve actually seen it for sale. I collect a lot of soundtracks — not so much to have them, but to actually listen to and enjoy them — and this was one of the very last ones to add to my collection. I’m pretty excited. Oh, and the score in question is Patrick Doyle’s Shipwrecked. I tell you whot. :)

Advertisements

gotta love gentoo

I was listening to some music I was streaming from my box at home to here at work as I setup some stuff, and while I was compiling an upgrade in the background, my Beep Media Player stops randomly. At first I couldnt figure out why, then I remembered that it tends to do that when CPU usage is running high.

So, I goto the BMP webpage to see if there have been any recent bugfix releases. Nope, but someone has forked it to a new project called audacious. That’s cool, let’s go look at that website. Seems like they’ve already put out a few bugfix releases since the fork. Wow, that’s even cooler. Now, let’s *really* push our luck and see if its in portage. Hot crap, it is.

Man, I love Gentoo. :) Those corndogs that make those ebuilds are so on top of things, it’s amazing. I wish I could program that stuff.

ghosts in the machine

I was talking to my friend tonight about my random problems with the database at work. There are just random things that happen to it, that we cannot figure out for the life of us. We’re planning on switching to PostgreSQL but it’s slow goings. In the meantime, we deal with it best we can.

Anyway, here’s what I was yammering about to him on IM:

“The thing is, theres two types of problems.

Problems you can track down. They are logical. You can see them break. Something you did, something you changed, or flipped, or activated, or deactivated or turned off or ran or installed or uninstalled or clicked will have made something else happen.

I can handle those problems. I might go bald pulling my hair out figuring out where it comes from, but usually you can find them okay by applying common sense, _patience_, logic and perseverance.

The second type of problem is ghosts in the machine.

When nothing has changed, everything is green lighted to be okay, things have been stable for days / weeks on end, everyone is happy, there are no odd logs, warnings, errors, red flags, bad signs, omens, instincts.

And something breaks.

Windows is haunted.”

death to sql server (part 2)

This one isn’t a rant, just another head-scratching-that’s-an-odd-thing-to-do kind of post.

One of the main scripts was running slow tonight that gets hit on a regular basis, and we couldn’t figure out why.

So, we do what we do when we aren’t sure what to do — we reindex the table. That’s the first general fix we like to do. Turns out, that fixed it in this case, as well.

What had changed recently you might ask (and well so)? We added a column to one of the database tables.

I guess that was too much of a strain for SQL Server.

death to sql server (part 1)

Just for a background .. anyone who has talked to me for more than 30 seconds about databases knows that I hate Microsoft SQL Server with a passion. The real bonus is that it’s not just an unfounded passion! I have proof of its inadequacy, which you’ll see in this special 5,789-part story.

In today’s adventure our hero ran into a small problem — he wanted to select year-month-day from the database in the format of (2006-01-17). Easy, you would think, until you’ve actually worked with the database first hand.

First, I tried selecting them all individuall and concatenating them together .. which worked, except that datepart() won’t pad the zeroes (it would return 2006-1-17).

Next, I decided to write my own UDF (User Defined Function for the unwashed masses), which would set the variables, but I ran into another problem — you can’t run getdate() within a UDF. That’s weird (translation: That’s about the dumbest thing I’ve seen this databse do yet).

Actually, the last problem turned out for a small bonus, because with my new UDF I could just pass it in as a variable anyway. Sure it complicates the function a little bit, but it will work out in the end.

Speaking of which, here is the final SQL for the function:

CREATE FUNCTION dateYMD(@getdate DATETIME) RETURNS VARCHAR(255) AS
BEGIN
DECLARE @year CHAR(4);
DECLARE @month VARCHAR(2);
DECLARE @day VARCHAR(2);
DECLARE @date VARCHAR(255);

SET @year = YEAR(@getdate);
SET @month = MONTH(@getdate);
SET @day = DAY(@getdate);

IF LEN(@day) = 1 BEGIN SET @day = '0' + @day END
IF LEN(@month) = 1 BEGIN SET @month = '0' + @month END

SET @date = @year + '-' + @month + '-' + @day;

RETURN @date;

END

Then, the final blow. After about getting halfway through writing this one, I find that there’s an undcoumented feature (I guess those Microsoft developers enjoy Easter Eggs just as much as I do) to do the same thing I was doing:

SELECT CONVERT(VARCHAR, GETDATE(), 23);

SQL Server: 1, Developer: 0