Stored procedure error handling in SQL Server 2000

Today, we’re continuing work on our multipart message aggregation upgrade for a future Esendex release.

One part of the investigations this morning has been looking into how we manage the database access as we add parts of an incoming message to it for later processing. As we have multiple servers processing inbound messages, there was the potential for two threads trying to write to the database simultanously with different parts of the same message. Both could look at the database and think there were no existing parts of a multipart message, and decide to try and insert a new multipart message record.

During this work we found out that SQL Server 2000 will still raise an SQLException error despite error handling put in T-SQL.
Continue reading Stored procedure error handling in SQL Server 2000

Of spam and things…

It’s been a few times this last year that I’ve been the victim of a domain spam attack. Sending email appearing to be someone else isn’t a difficult thing to achieve. Yet when someone takes one of your domains and sends spam, well I was going to say on my behalf but I never asked them to, it gets very annoying.
I’m currently processing over 50 emails a day with people’s email servers returning spam blocked or unknown mailbox responses.
Continue reading Of spam and things…

Checking it out

I have a feeling that a lot of small to medium development operations will still be using Microsoft‘s Visual SourceSafe to manage their central code-base despite its limitations.
Given that Microsoft have since addressed this hole in their development offerings with the excellent Team Foundation Server which offers a seamless experience within Visual Studio 2005 and a raft of source control features woefully missing from Sourcesafe.

Not wanting to turn this into too much of a rant about SourceSafe, today’s observation concerns SourceSafe’s supposed ‘Multiple Checkout’ feature when used with Visual Studio 2005.
Continue reading Checking it out

Have you got the Bug?

Being involved in web development work, I have to have a wide range of browsers installed to make sure what I’m creating is accessible to as many people as possible. Whilst I still have a soft-spot for Opera, it is without a doubt that Firefox is the Swiss Army Knife of all browsers.
The ability for developers to add-on functionality has created such a rich platform for linking useful tools with web browsing that there’s nothing finer in my humble opinion.

Here’s a few addons that I can’t live without:

Continue reading Have you got the Bug?

Credit card regular expressions

Following on from my previous post about credit card authentication with regular expressions, I thought I’d share my other discovery.
The BIN Ranges list I found showed a list of Visa cards which were designated ‘ATMOnly. Figuring these would be a good thing to filter out during validation.
There’s plenty of regular expression help about joining pattern matches with logical OR clauses, but what about wanting to specify patterns which prevent certain things coming through?
Continue reading Credit card regular expressions

Maestro, music please

We’ve been working on a change request to add Maestro to the credit cards that we accept for ecommerce payments. Switch started in 1988 but has now merged with the Maestro network owned by MasterCard in the UK.

Until recently, if you took Switch payments then UK customers who had new Maestro cards would still be ok (as long as you accepted the new 6759 prefix for your payments) however with the merging of the worldwide card base there’s a whole new set of card numbers which need validating.

A quick search on 18-digit Maestro cards that HSBC have been issuing raised a few e-commerce shopping cart forums where people were confused about these new card types. So I thought I’d share my findings:
Continue reading Maestro, music please

Credit card validation

We’ve been updating the e-commerce side of the website to work with Maestro cards in the near future. As a result, I’ve had my first delve into card processing and some of the simple techniques that you can use to validate a card before submitting details to a bank / online card processing service.

The strange sounding Luhn Algorithm is used as a quick checksum of the credit card digits (and a few other things) and will detect most transposed digits. Continue reading Credit card validation

XP’s Command Prompt retains old environment variables settings

The following post is courtesy of the IMMWITWIGIOTSS Society to save your brain while it’s still pressing Snooze at home.
Logic would dictate if you update the PATH environment variable then you’d hope the next command you uttered from the command prompt window would use this updated information. You can keep typing ‘echo %PATH%’ till the cows come home but your settings won’t appear to have changed.
Just close the window, open up a new command prompt and save your brain cells.
Yes, we tripped over this this morning, but it was BC.

Welcome to dev:ices

I’ve decided to give my development blog a new lease of life since the reinstall of the server. I guess the other reason I’m hopeful about continuing to blog more is the discovery of ScribeFire which plugs into Firefox and seems to make the whole process of blogging a lot easier. Not least the ability to reference the page you’re currently browsing, so I’m looking forward to playing with that.

And with my new job at Esendex if I come across any interesting programming insights in the process, I aim to share them here. Any personal ramblings will continue to be on Badger.