Sunday, April 26, 2015

First "real" job with SQL.

My next job was the first one I got directly due to my knowledge of SQL.  So, why not go right to the source?  Microsoft SQL Server support.  Unfortunately my stint here was pretty short due to finding it incredibly boring.  Worked there for about 9 months, last 4 or 5 months as Server Down support, including being the only person in the US supporting SQL on  Sundays.  Guess the use of our choice in databases has grown a bit since 1997.  It was a very rewarding job in many ways, just the calls where getting very repetitive and I was getting major worries about stagnating in my skill set.  One can only do so many database corruption fixes in one week before things get really boring.

One day my mentor from NDS called.  2 weeks later I was employed there as a SQL Consultant.  So after years of complaining about those Highly Paid Consultants, I was one of them.  5 years with the company I did quite a few interesting things, and a lot of not so interesting.

This being the heyday of companies starting to switch from legacy applications (AS/400, DOS, Novell) to Windows, and then to internet, there was some good times and a lot of helping companies out getting the most out of their new systems.  Many times this meant helping management understand what we could do with Windows, and a lot of it was just to teach them to do away with old ways of doing things.  Fighting bad habits became a habit!

Some highlights from this period, names of clients withheld to protect the guilty.

Wrote an application that had to load millions of records a night, and then do processing of the records.  This was my very first project as a consultant, and the one I specifically got hired to clean up the mess.  My company had had 2 developers working on the problem for 3 months, when I got there it took over 36 hours to load one day worth of records, and they had never got to the point where the records could be used.  The records contained phone call information for a calling card reward program.  The system was to be used in the clients call center to give out the rewards, or dispute bills, because of this the data needed to be summarized up front since at the time the hardware they had for this could not summarize the data on the fly.

This is the ONLY time in now 20 years of working with SQL I used a CURSOR as the solution for performance improvement, and since I was already looking at each record did an update to the summary table while I was in there working on each record.  This solution was a long shot, but the solution the 2 others had come up with looked like it should have worked.  By the 2nd day I had the query down to about 3 hours, which was good enough for the client, but I talked them into letting me stay for the week and had it all down to 30 minutes.  And while it did not make me a believer in cursors, it at least proved that the only answer in SQL is "it depends."

Another fun project was a background check solution.  This one we converted from Fox Pro (an old version of Fox Pro even in 1996).  Initially they requirement was to load the data into SQL, then do a cut to the SQL based system.  The more I learned about the system this seemed more and more strange to me.  After a while I convinced them that we could make a lot better system if we could just ignore the old data, and start from scratch, since their data was useless after 90 days I convinced them to just run the two systems in parallel for 90 days.  Since I guaranteed them the new system would be a lot faster if we did this, they let us proceed this way.

Besides that, this was an interesting client.  Small family run company with rather relaxed dress code.  One day the owner came over and asked me why I was always dressed up with a tie etc.  Explained that it was the required dress code for all out consultants.  He told me promptly that as long as I was on site at his company, I was no longer allowed to be dressed up.  Jeans and a t-shirt.  At the most.  A few weeks later my boss came by to check on the project and was mad as hell about me not being dressed up, calmly explained to her that it was the clients requirement.  My company changed our dress code to be "average level at the client +1."

One day mid 1997 I was sent to a client to check in on their performance problems on a SQL Server running on 4 Pentium Pro 200 CPUs, which at the time was big time metal.  I solved the problem within 5 minutes of walking in the door.  I felt kind of bad about this since we charged 4 hours minimum for my time whenever I had to go onsite.  I walked into the CIO and told him that and asked if it was anything else I could do for him.  "Yeah.  Give me spec for your dream SQL Server," which I proceeded to do.  He then leans over the phone and asks the person on the line if he got that (I had no idea anyone was on the phone!).  Turns out he had HP sales person on the line, got the quote ($100,000) and ordered two of them.

When I got back to the office I told my boss what happened.  She got mad that I did anything outside the scope on the contract.  Told her I thought it was a good thing and that we would get more work from it.  I ended up being at that client for 2+ years working on ETL systems for some of the major oil and food companies in the world, during most of that time we had between 1 and 4 other employees there helping me out as well.  All because I was 100% honest up front.  So much so that the CIO after a while banned their sales people and my boss from putting foot inside the company, he would send all requirements for personnel through me and take my word for it that someone was good enough for what he needed.  Off course the sales person on the account got all the commission.

While working for NDS I also got fired from a client for the first and only time in my career.  Got called on a Friday night with a performance problem at a major newspaper.  Through some intense work we managed to cobble together enough performance to get the Sunday paper out, after about 80 hours of working straight I was getting pretty tired.  In that time: we had moved it from running on a DEC Alpha based system due to a bug in the ODBC code that kept corrupting the data, this involved BCPing the data out and in, de-normalized the database since it was too normalized from SQL 6.5 too handle (hint: when street number is normalized you might just have gone too far), I had made enemy out of someone that was a professor at a University that had designed the database by calling him incompetent (ok, I just told him he needed to get out in the real world a bit more), and an assortment of other problems.

About 10 AM on Monday morning, I am sitting in their operations center with the CIO on my left, their DBA on the right (both had stayed with me the entire time!), and the CEO behind me.  I'm looking at some performance numbers on the server and the CEO comments "that is not how our DBA does it" whereupon I answered "your DBA couldn't get the paper out, I did."  Shortly thereafter I went home and went to bed.  A few hours later I was woke up by my boss who informed me I had been fired by the client, but she couldn't figure out why since she always had very positive feedback on me.  Told them the above, and figured that was it.  10 minutes later the CIO and DBA call me to tell me, says it was not their call but could not stop the CEO.  They still wanted me to personally find them two SQL devs/DBAs to help them out.  Good times!

To be continued.

No comments:

Post a Comment