Click here to monitor SSC

Phil Factor's Phrenetic Phoughts

Simple-Talk columnist
The wilder shores of Transact SQL    Phil on Twitter   Phil on SQL Server Central  Phil on BOS

I could do it in my sleep

Published Thursday, February 23, 2006 10:01 PM

Like many other programmers, I have adapted to a rather cat-like lifestyle of intense activity followed by relative languor. This coincides with the cyclic nature of the industry: Either there is too much work or too little. At the moment, there’s too much work, so I’m tending to work around twelve-hour days, often more.

Of course, insomnia isn’t a problem; not with my copy of ‘SQL Server 2000 with XML’ on my bedside table. Two pages, and I am insensible, even if I pick it up at noon, after drinking strong coffee. Every doctor should prescribe this book. I recommend it unreservedly.

Definitely, insomnia isn’t my problem when I’m tackling a high workload. The worst problem is being hardly able to see the screen by the end of the day. Almost as bad is the fact that I carry on programming in my sleep. In this strange state of unconsciousness, I’m not entirely sure what I’m programming, or why. This is, I suppose, not far off the everyday work experience of the average developer. What is more alarming though is that, after putting in eight hours of sleep-programming, the whole lot gets lost on waking. Sometimes, I am even heard to cry out ‘Save, save!’ when being shaken awake in the morning.

I can normally remember nothing of what I’ve written in my sleep, but recently I seem to have been working out procedures in Transact SQL  for zipping or ‘Huffmanising’ text. This was triggered off by my penultimate blog, on Teddy. I was hoping to entice other people in doing so, in order to munificently issue a glittering prize, but nobody took up the challenge. I don’t blame them, but I tried it myself to make sure it was possible and, despite my complete ignorance of the algorithms, I reduced the storage requirements of ASCII art down by 80%. Even ordinary text boiled down 60%. It is an idea that, for some reason I can’t leave alone, and I keep getting ideas for improving the method that I then have to tap in hurriedly after breakfast before the memory fades.

I’ve always wondered why it is that a programming problem that seemed so daunting the previous night has a simple solution when the morning comes. ‘The phrase ‘I’ll sleep on it’ could describe the strange way that the brain keeps doggedly chipping away at problems. Maybe one actually does remember the conclusions of all that unconscious programming effort. Now all I have to do is to work out a way of charging all that sleeping time to my clients.

Some programmers I know actually manage to charge hours spent asleep to their clients. One of the strange techniques one can acquire when being paid by the hour is to be able to sleep whilst giving the appearance of staring in intense concentration at the screen. I'm hopeless at this. Whenever I fall asleep whilst programming, I wake up with the neat impress of the keyboard on my forehead. Alternatively, I end up with my head flung back, mouth open, snoring loudly. Neither type of shut-eye inspires the confidence of ones employers.

There was a time in the IT industry, before laptops and Powerpoint, that salesmen used to employ slides and slide-projectors. The wonderful thing about these devices was that the room had to be plunged into darkness for the slides to be seen on the screen. Many a salesman must have wondered why there were so few questions about his splendid products, or why nobody laughed at his jokes, when he was giving his pitch to a roomful of developers. Once or twice, I have suddenly switched on the lights to be met by a scene reminiscent of the aftermath of the Hugenot Massacres. Still bodies slumped everywhere.  Sales presentations seemed to be a universal trigger for sleep amongst  IT staff. Ah me, the cruelty of technical progress.

To be fair, all this is the reaction to the demands made on developers to work ridiculously long hours. I suspect that, out there, there are others who have adapted in ingenious ways to the pressures of the job, and of course we'd love to hear from you.

Comments

 

Andrew said:

The strangest experience I ever had was whilst working for an IT company funded by the Middle East. I was one of the very few non-muslims in the organisation. I was supervising a small team of muslim programmers. They were charming people, who worked hard for long hours. They were a great team.
There was a mosque within the building, and the staff had to disappear off to pray occasionally. After a while I noticed that when stressful emergencies happened, such as a production database locking up solid because of a process table-locking, I was the only person around to fix it. Of course, the mosque was the one place I could not pursue the team to check on them. Well, there and the ladies toilets.
When we eventually get laws enforced to make places of worship compulsary in the workplace for all 'Faiths', I suspect I shall become a born-again Christian. Intense prayer is remarkably restful during the working day, especially when one is charging by the hour
February 25, 2006 10:02 AM
 

Arthur said:

At a company I once worked for, there were a number of contract programmers. One of them knew the process control system, that the product we manufactured depended, on inside out. When the usual panics set in when the release of a new model was delayed, he had to work twelve hour days to sort the software out. He used to jump straight out of bed, get dressed and head for work, at six in the morning. After an hours work, he would wash, and do his morning ablutions etc, before continuing his work, charging the company for the time he spent on doing so. And why not? If the comany wanted him to work inhuman hours then it seems reasonable that they should pay. However, he admitted that it gave him a certain grim satisfaction that he charged the company for the time spent on the toilet in the morning.
March 4, 2006 5:46 PM
 

Alan said:

I once tele-commuted for a company that paid me based on the time I logged in to the time I logged out. So, of course I set my alarm for 6am, got up, logged in, went back to bed for an hour or so, got up, washed, had breakfast, then sat down at my terminal to begin my day.

Whenever there was something my budget didn't allow for, well, I just stayed logged in till well after dinner for a few days....

God, I miss the old days!!!!

March 6, 2006 8:36 PM
 

Phil Factor said:

Of course, the old timeshare systems used to check on the keystrokes, so they'd have noticed that you weren't typing in much. I remember taking to an old programmer who claimed that he used to take one of his hens into the room where the terminal was and, while he was elsewhere, scatter grain over the keyboard. As the hen pecked amongst the keys, it would send keystrokes.
March 8, 2006 2:41 PM
You need to sign in to comment on this blog
Latest articles
A first look at SQL Server 2012 Availability Group Wait Statistics
 If you are trouble-shooting an AlwaysOn Availability Group topology, a study of the wait statistics... Read more...

SQL Server Prefetch and Query Performance
 Prefetching can make a surprising difference to SQL Server query execution times where there is a high... Read more...

SSIS Basics: Setting Up Your Initial Package
 When working with databases, the use of SQL Server Integration Services (SSIS) is a skill that often... Read more...

Checking Out SQL Backup Pro 7’s New Automatic Backup Verification
 Wouldn't it be great to offload the daily chore of checking the integrity of your production... Read more...

Chuck Lathrope: DBA of the Day
 Chuck Lathrope was a finalist for the Exceptional DBA of the Year award in 2009. We contacted him to... Read more...