Getting a pizza the action, AS/400 style

It looks like you need some pepperoni and cheese. Do you want some help with that?

190 Reg comments Got Tips?

Who, Me? Monday has shuffled into view once more and brought with it another Register reader confession in the form of our regular Who, Me? column.

"Charles," for that is most definitely not his name, is the culprit this week in a cautionary tale of why displaying some sort of confirmation text is probably a good idea.

Our story takes place back in the mid 1990s, where Charles was running an AS/400 and PC network to support a regional gas company.

The AS/400 was an IBM mid-range computer and launched back in 1988, succeeding the System/38 minicomputer of 1979. Compatible with much of the legacy code that went before it (to the point that AS stood for "Application System") the hardware did sterling work for small and medium sized business before being succeeded in 2000 by the IBM eServer iSeries.

For Charles, it was a tool for perfecting the company's Just In Time (JIT) propane delivery experiment on which he and the team laboured long into the night.

Keeping developers going is a challenge for many a manager, and energy boosting beverages such as Red Bull, Happy Bunny Spaz Juice, good old fashioned coffee and diet coke all play their part. But to keep the engine running there is really only one fuel: pizza.

Rather than talk to an actual human, Charles opted to exercise his coding skills: "I wrote a quick proc to order pizza, it simply sent a fax to a local pizza shop with the order, I set flags to determine how many and what kind of pizzas."

Helpfully, "the proc was named 'pizza' with the flags following the proc."

So, a hungry developer could just type pizza into the command line, specifying the mountain of pepperoni needed and, presumably, if the cake-like 'Chicago Deep Pan' variety was required. The requested meal would then be delivered even if there may have been no accounting for taste. We can but hope that there was no flag for pineapple, for down that path lies savagery.

Pizza was arguably ahead of its time if one considers the food delivery needs of today.

All went swimmingly for a few months until Charles was yanked from a staff meeting by the receptionist. He had a delivery.

"56 pizzas."

Oops.

Fearing the worst, Charles ran a report and saw that his little utility had indeed been used. A sales clerk had entered the command 56 times and then scarpered when the mountain of pizza turned up.

"Luckily," said Charles, "the president of the company found it quite funny and paid for the pizza out of petty cash and the whole company got a free lunch."

The new hero of the company (at least as far those not responsible for the petty cash were concerned), Charles eventually caught up with the sales clerk and discovered the flaw in his nifty utility.

The clerk "admitted to typing pizza and pressing enter, but it didn't do anything, so he tried it 55 more times."

Pizza, pizza, pizza, pizza...

"I changed the security settings on pizza so only admins could order pizza and told the pizza shop there would be no more than one order at a time."

Hopefully he also added a bit of text along the lines of "Thank you for your order! Now please don't type 'pizza' again..."

Ever found your helpful bit of code abused by the unwary? Or had the boss cheerfully pay-up when all seemed expensively lost? You have? Then it is time to send an email to Who, Me? and share your story. ®

SUBSCRIBE TO OUR WEEKLY TECH NEWSLETTER


Biting the hand that feeds IT © 1998–2020