Comparing 2 set of data from 2 different dates

Saturday, September 17th, 2011

In last Friday training, one of the participants came with an exceptionally interesting problem. On a weekly basis, she needs to donwload a spreadsheet from the HR systems which will list down the employees’ profiles, such as employee ID, Name, Department, Reporting Manager, etc. Using the downloaded worksheet, she has to compare the details against the previous week worksheet and identify the changes that have taken place. The first answer i thought of is to use VLOOKUP. But the “problem is there are more than 20 columns and any of these columns could be different from the previous week. And there are not just a few rows but a few thousand rows. So how on earth can we identify all the cells from 20 columns x say about 6000 rows, total of 120,000 cells? Impossible if we are to eye ball at every cells.

The solution called for the use of VLOOKUP formula using employee ID as the lookup value plus conditional formatting. Using a formula based conditional formatting option, we can input the VLOOKUP formula (to pick up the data from the previous week) and compare the result with the value in the current cell. (Take note that this is not the normal VLOOKUP formula. You have to setup the VLOOKUP formula so that it will return the value TRUE or FALSE, the basis for conditional formatting to work). If the values are different between the 2 weeks, the cell will be highlighted with a colour. This will allow us to zoom in into the colored cells and work with them. Of course, this is based on the assumption that most of the cells would remain the same between the 2 weeks. We have to make the formula more dynamic and To make the formula dynamic, we have to add in the COLUMN formula so that it can automatically change it’s value as you apply the conditional formatting to the right and down the worksheet).

Create a list with no blank cells

Saturday, September 17th, 2011

Somebody sent me an excel file containing a list of hospitals in Column A. In the first row, it listed 40 different types of rebates. For each hospital, only certain rebates were used.

List with no blank cells

He would like to create a dropdown list for each hospital, showing only the rebates that contain a value. For example, he would like the dropdown list to show only Rebate1 and 3 for hospital 1 because only these 2 rebate columns contains values. He asked if it can be done.

I have tried googling on whether I can create a list with no blank cells before and couldn’t find a solution. But I deceided to try again. To my surprise, I managed to find a few websites that demonstrated how it can be done using formulas. One of them that explained how it can done can be found here.

I modified the formula to do it for columns. Then I setup the formulanbsp;such that he can do a double selection, select an hospital first before showing the list of rebates. This involved the use of the all powerful OFFSET formula to complete the solution. To see how it works, download this excel file.

About Edate

Friday, September 2nd, 2011
Question: We use edate function for finding the date after  certain months .do we have similar functions for years and days?
Answer: As far as we know, edate is the only function in Excel. For years, we always multiple the number of years by 12. EYear is not really necessary because the number of days is consistent for the months in every year except Feb. There is no need for days, just add the number of days to the start date.

Extract data within brackets

Thursday, August 11th, 2011

I want the word in brackets to appear only (Under the Class Column). Eg:

Degree Class

You can use the formula


Or TEXT-TO-COLUMN with “(“ as the separate. To remove the “)” use find “)” and replace with nothing.

What if I want the data from within the 2nd bracket?
Degree Class


You can use the formula.


Why HR need to use Excel?

Wednesday, May 11th, 2011

1. To monitor the renewal of passports/work permits

2. Calculate anniversaries of employeesbr

3. Track trainin programs attended by employeesbr

4. Analyse benefits paid out

5. To compute salary details including CPF.


Display Product Image (con’t)

Wednesday, April 27th, 2011

Yesterday, I saw a promotion list and found that there were too much information in the print out. It reminded me of a price list that I had from a distributor. There were thousands of products in the list and navigating through the list was a nightmare. So I decided to improve on it with 2 dropdown lists, one for selecting the product model and the other to select the product code. The second list is dependent on the selection on the first list. It helps to zoom into the particular product group and reduce the no of models for selection from a few hundreds to a few. And combined with the Display Product Image solution, I can now view a particular product model and the given description easily. Download this file for more details.

Display Product Image

Wednesday, April 20th, 2011

This solution is created with a combination of functions and formula. The frame for the changing image is created using the Camera function in Excel. Adding the Offset and Match formula make the address reference change according to the product code appearing in Cell H2. We use data validation to create a dropdown list for users to select the product code to display.

Autofill Frustration

Thursday, March 24th, 2011

Question: when I drag a date to the line below it, the date advances by one day. I don’t want this. I would like the same date to drag down each time

Answer: If you turn off autofill, you will also turn off the ability to drag cells down. I don’t think this is what you are looking for. An alternative approach is to highlight all the cells you wish to fill, type the value and then press Ctrl + ENTER at the same time. It will help you fill up the highlighted cells with the same date.

Financial Quarters

Friday, March 18th, 2011

If your company has financial year that does not coincide with the calendar year, you will have problem presenting your numbers in Financial Quarters, especially when you have to work with hundreds or thousand of records. But by employing a few formulas, this job can be done in just a few minutes. Take a look at my new write up on Calculating Financial Quarters

find a particular word from of group of words in a cell

Monday, March 7th, 2011

can excel find a particular word from of group of words in a cell and in turn should give a particular output for a particular text, the text needs to be searched and the output which needs to be displayed will be given when created so that from the next time if it finds that text it needs to give the output which is mentioned earlier, can you please help me on this?

You can use the SEARCH formula to find the word. Combined it with IF and the ISNUMBER formula. Assuming that the list is in column A and we are working on A2. The formula to place in B2 would be