Saturday, December 24, 2005

Captain Drool says 'Merry Christmas!'

Seriously, a very Merry Christmas to all (read: both) my readers.

Friday, December 23, 2005

Beware: I Slam Doors

Dear Everybody for whom I've ever held the door open (that felt they needed to put their hand on the door as they passed through it):

You'd better thank your lucky stars that you put your hand there. If you hadn't, I would've waited until you were halfway through it before crushing you into the door frame and laughed all the way back to my desk as you lay there twitching.

Friday, December 16, 2005

Party Photos and BitMail

Here are the pictures I promised from last night's gathering.

So, I started seriously pipe-dreaming about how cool my little Bittorrent/email app could be. I dreamt of platform independence, the ability to use any old BT client program, response emails, etc. Then I realized something:

Nobody is really going to use this, except for me.

Having made that brilliant discovery, I pretty much changed it so that it runs fine on my Mac. It'd run fine on other platforms with a few very small modifications, but I didn't bother abstracting that stuff out to make it easily configurable. Call me lazy, but I just got tired of it not being finished.

Now, if any of you blokes out there want to futz around with it, you can get the latest version by issuing this command (obviously, you'll need to install darcs - darwinports has it, if you're on a Mac):

darcs get http://inkedmn.homelinux.org:8000/repos/BitMail

Oh, and it's called BitMail now :)

Anyway, try it out and stuff.

Thursday, December 15, 2005

My Sentiments, Exactly and a Life Update

Oh, crap, I still have a blog...

Sorry to have neglected you, dear friends. I've been busy.

Colin Walters put up a blog post that perfectly describes my reasons for not hosting a web/mail server myself. Nutshell: Practicality overtakes Pride.

In other news...

Holden will be 5 months old on Christmas day. Pretty freakin' unbelievable. Before we know it he'll be running errands for us.

We're having a little holiday gathering at our place tonight, should be fun. I'll probably post some pictures later.

For no longer being a programmer at work, I sure am doing a hell of alot of programming these days. Currently working on a Webservice + socket client dealie to do credit card authorization and batch settlement for all of our stores and salespeople. Having a great time dealing with the technical dimwits at the credit card company. Here's a small sample of what the dialog has been like:

Me: I have a question about something in the Request Format spec.
Them: Read the spec.
Me: No, my question is regarding (one of the many ambiguous points contained in) the spec.
Them: Oh, ok. Read the spec.
Me: I hate you.
Them: Read the spec.

Now, after you've changed your shorts (since you obviously soiled them in laughter while reading that), please understand that while I was embelishing a bit, it really was about that ridiculous. They seem to be totally unwilling to work with me. I ask for examples, I get another copy of the spec emailed to me (oh, and this one is current, not the year-out-of-date one we gave you by mistake).

So, that part has sucked, but I'm actually learning quite a bit about the credit card stuff and have a whole new respect for the people who write this crap.

By for now.

Saturday, December 03, 2005

Aw HELL Yeah


Just like Dad
Originally uploaded by inkedmn.
Start 'em young, Ethel...

Friday, December 02, 2005

An Experiment (with special bonus GARBAGE SQL script)

Gonna try posting some source code that I wrote for a friend today. It's really horrible and I'm embarrased to be posting it.

Here goes:



SET nocount ON

declare @foo varchar(10)

SET @foo = 'abc123'

CREATE TABLE #tmpLetters (
letter char)

INSERT INTO #tmpLetters (letter) values ('a')
INSERT INTO #tmpLetters (letter) values ('b')
INSERT INTO #tmpLetters (letter) values ('c')
INSERT INTO #tmpLetters (letter) values ('d')
INSERT INTO #tmpLetters (letter) values ('e')
INSERT INTO #tmpLetters (letter) values ('f')
INSERT INTO #tmpLetters (letter) values ('g')
INSERT INTO #tmpLetters (letter) values ('h')
INSERT INTO #tmpLetters (letter) values ('i')
INSERT INTO #tmpLetters (letter) values ('j')
INSERT INTO #tmpLetters (letter) values ('k')
INSERT INTO #tmpLetters (letter) values ('l')
INSERT INTO #tmpLetters (letter) values ('m')
INSERT INTO #tmpLetters (letter) values ('n')
INSERT INTO #tmpLetters (letter) values ('o')
INSERT INTO #tmpLetters (letter) values ('p')
INSERT INTO #tmpLetters (letter) values ('q')
INSERT INTO #tmpLetters (letter) values ('r')
INSERT INTO #tmpLetters (letter) values ('s')
INSERT INTO #tmpLetters (letter) values ('t')
INSERT INTO #tmpLetters (letter) values ('u')
INSERT INTO #tmpLetters (letter) values ('v')
INSERT INTO #tmpLetters (letter) values ('w')
INSERT INTO #tmpLetters (letter) values ('x')
INSERT INTO #tmpLetters (letter) values ('y')
INSERT INTO #tmpLetters (letter) values ('z')


declare lc cursor fast_forward
FOR
SELECT * FROM #tmpLetters

declare @letter char
declare @hasalpha bit
SET @hasalpha = 0

open lc

fetch next FROM lc INTO @letter

while @@fetch_status = 0
begin
IF (CHARINDEX(@letter,@foo) <> 0)
begin
SET @hasalpha = 1
end
fetch next FROM lc INTO @letter
end

close lc
deallocate lc

DROP TABLE #tmpLetters

IF @hasalpha = 1
begin
print 'Has Alpha Characters'
end
else
begin
print 'No Alpha Characters'
end

SET nocount off

Don't you feel just a little bit sick? A temp table AND a cursor to find out if a varchar contains alpha characters...

Vomjom claims to have a one-liner that will do this. I'll post it when he gives it to me (Mark: I think we have a peed-on doctor's note situation here...)

[EDIT]

And, we killed the fly with the shotgun once again. Here's the quick way:


declare @foo varchar(10)
set @foo = 'abc123'
IF(@foo LIKE '%[a-z]%')
BEGIN
print 'Has Alphas'
END
ELSE
BEGIN
print 'No Alphas'
END


Live and learn, I suppose...

Thursday, December 01, 2005

Funnay