Wednesday, May 30, 2012

HURR MS WORD !!

There is an existing looong SQL query which selects some products for a condition where Sub product like ‘%Bill - Option%


Now as a part of an enhancement a request came from a user (via email in Outlook) to add a new Product with Sub Product Bill – Option 
One of my team mates  worked on this and added the new product in a table.. Simple Enough..!!


UAT Started and today the User came back saying that the new product is not being selected.


I was called in for help and after breaking my head for 1 hour determined that the team mate who added the new product, copied the Sub Product name directly from the User’s Email and entered into the table.


Now Microsoft Word on typing a - changes it to a slightly longer version of – .


This is clearly visible here in Outlook but when you look at these two things in SQL. They look exactly the same.


Example: 



(The two above are different; one is a copy from Outlook the other typed). 


One works, the other doesn’t 
Can you guess which is which?


So a Boon for Word/E-mail writers proves to be a curse for a developer!!


Why am I writing this? Coz I am super frustrated after finding the reason for this  error.


Have a Nice  Day !!

THIS IS COSMIC BLASTING OFF !!!!!!!!

Friday, May 18, 2012

Dead Line

Trupti sat late on a Friday evening in the office. The office was empty as everyone had left on time except her. The office was dark and the only source of light was from her own monitor.
She was stuck trying to debug a particular tricky piece of code. 
This application called SRC had been handed over to her only 6 days ago and she had to remove 4 bugs from the application in a week. 


Trupti was confident that should we able to tackle the issues very easily as she had done multiple times in the past and meet the dead lines comfortably. That was the reason that her supervisor had full faith in her talents and had handed this seemingly easy piece of work to her. This would be the 8th and final project which she would have to complete in 2011.


But this application was proving to be a tricky one. Even after 6 days she was nowhere close to even re-producing the bugs.


After 2 days when she had asked her supervisor if any documentation exists for the code, she was informed that none did. The developer had written none.


Again after 4 days when she had made no progress she asked her supervisor if he knew who the developer was so that she may directly try and contact him and clarify some of her doubts.


Again she was frustrated and intrigued to know that no one knew who had written this application, who the developer was, what was their name or where they were now. Roy in the support team had mysteriously stumbled upon this code one day in Source Safe in a location where he was sure there was no code before.

Today being the last day Trupti wanted to complete her work before Monday so that she wouldn’t need to come to office on the Christmas weekend.


The clock was getting closer to 11:00 now and she had her last office cab at 1:15 in the night.
This was the last hour which she had to find the solution or else her weekend would be ruined.


She delved back in to her system, fully concentrating only on the screen oblivious to her surroundings.
When suddenly she heard the chair from the cubicle across to her squeal. She recognized the voice immediately as that’s where her team mate Megha sat. But Megha had left at 6, then what was she doing now back in the office so late.


She got up to check and was surprised to see a girl who she had never seen before sitting in Megha’s chair staring at her screen which was switched off.
Trupti was taken aback for a moment, but then gained back her senses and thought that this girl might e from the cleaning crew. But she then noticed the Tag and the Id Card around the girls neck. She was from her own company, but her Id Card was of the format which the company had stopped using many years ago.


Trupti finally gathered enough courage to ask the girl who she was and what she was doing here. As the girl looked up at Trupti the clock struck 12 and Trupti was distracted for a second when she turned to look at the Clock. When she turned around the girl was now standing besides Trupti with a sweet smile on her face. Trupti stumbled back stunned. But the girl caught her arm before Trupti would trip over and fall down.


She introduced herself as Archana and told Trupti that today was the first day for her in this office and she was part of a different team. As Archana was getting bored she had come over to see if anyone else was in the office when she had found Trupti.


Trupti then got back to her code as she wanted to leave by taking the cab. Archana offered to help her with the code. They both sat down together and around 1:05 in the night miraculously all the bugs were resolved. Archana did most of the work. It was as if she knew each and every piece of that code like the back of her hand.


Trupti was glad and thanked Archana profusely for her help and that now she can finally leave peacefully.
Trupti started to leave when Archana called her from behind and asked her to come back to the screen to add one final line in the code which they had forgotten.


When Trupti looked at the screen she could see a long list of names and dates in front of them when those people had edited the codes.
Trupti quickly jotted down her name and then noticed the name above her. It was
// Archana Sharma “Dead Line” – 13th August 2003.


The next day in the morning, the cleaning crew found Trupti dead in her cubicle, slumped on her keyboard with a sweet smile on her face.


In front of her the monitor was still on. The code was complete and the Cursor blinked on a line which said yesterday’s date:
// Trupti Bose “Dead Line” – 23rd December 2011


THIS IS COSMIC BLASTING OFF !!!!!!!!