On Sunday I discovered a new love for trailrunning. SNOW! The trails are completely transformed into a winter wonderland when it’s covered under a bed of snow. There’s a certain sense of serenity as I traversed the snow covered trails where the only things I hear are my footsteps over the soft snow covering a layer of leaves and the dead silence of early morning.

Instead of feeling tired and fatigued, each step I took reinvigorated my legs and gave me a sense belonging. I felt like I could’ve ran from morning to sundown.

I started at 7:30AM and finished around 1:30 ish for a total of 26 miles on the Greenway / Seneca Ridge Trail in Montgomery County.

Here’s the garmin data ūüôā

Seneca Trail

Seneca Trail




I turned 30 yesterday. Its not bad. Tricia and I went out for dinner & a movie. We stayed out until 1AM. We are by no means night owls so its a very rare occasion for us to be out that late.

I spent my Sunday (birthday) morning @ the running trails in the Agricultural Farm History Park in Derwood Maryland trying to get in 15 miles so I can end my running year with my first ever 100 mile week.

2012 was a great running year for me. My total mileage for the year is 3034.36

There were ups and down but I managed to stay injury free and still running well into 2013.

For 2013 the goal is to be consistent and train hard to finish the Vermont 100 race.

2012 Mileage

2012 Mileage

Microsoft Access as a backend database

I was recently tasked with making a Microsoft Access database more accessible by converting the current data entry screen into a web accessible interface. The data would still be store in the MS Access database but anyone can enter/search for information via the web interface.

The application will only be used on our intranet with the maximum # of concurrent users being 10 or less and hosted on a Windows 2008 server running IIS 7.

I was able to successfully read and store information to the Access database by following the tutorial by CodeFixer @

Data entry screen


Searching the database presented more of a challenge but luckily I ran into an excellent article by detailing on just how to put together such a search engine with support for multiple search criteria

This is what the SQL for my Select statement look like

SELECT [ticketNumber], [technician], [partNumber], [pcbSerialNumber], [problemDescription], [problemVerified], [noTroubleFound], [repairComplete], [boardUnrepairable], [badFromStock],[techCoreID], [techTime], [QCATech], [qcDate], [ynRepairable], [partsUsed], [notes] FROM [circuitBoardRepair] 


 (@ticketNumber IS NULL OR ticketNumber LIKE '%' + @ticketNumber + '%') AND 
 (@technician IS NULL OR technician LIKE '%' + @technician + '%') AND 
 (@partNumber IS NULL OR partNumber LIKE '%' + @partNumber + '%') AND 
 (@pcbSerialNumber IS NULL OR pcbSerialNumber LIKE '%' + @pcbSerialNumber + '%') AND
 (@badFromStock IS NULL OR badFromStock LIKE '%' + @badFromStock + '%');

Once the data have been entered the application also fully support editing and updating each record via the search page.

Search screen

I actually had a harder time getting the application to work on the server under IIS7 than developing it. There were so many specific nuances/settings that need to be set just right for the application to work the way its designed. Listed below are a list of things that I needed to configured on IIS7 for my application to work correctly.

1. Configure the application folder under wwwroot into an application

Convert folder to application

2. Change the default application pool identity to Network Service

Default application pool identity

3. Give Network Service “modify” rights to the folder where the database is stored

Folder permission for Network Service

4. and finally enable Windows Authentication

enable windows authentication

After a lot of trial and errors I was elated to get the application to work on the server the way I had intended during development.

Getting fresh… with JavaScript that is

One of my project for work this year is to port an old promise date calculator I had written in Microsoft Access to a more web friendly version. Originally I had planned on using ASP.NET for the conversion but after a few hours of research I decided using ASP.NET for such a small application is overkill and would put a lot of unnecessary CPU cycles on the server.

Such simple dates calculation are better off done on the client side via the browser. The obvious language of choice for this task is Javascript and with the ever popular jQuery ui library I can easily put together a working UI in as few as 15 minutes.

I used jQuery for the datepicker, since I am only working with business days I was able to find a CSS hack that disable weekends from the date picker.

<style type="text/css">
 /* remove weekends from popup calendar */
 td.ui-datepicker-week-end {
 display: none;
jQuery date picker

jQuery date picker

The premise of the date calculator is very simple. Given  a start date, date unit was put on hold and the original promise date. The calculator should programatically determine

  1. how many business days have passed between the date unit was put on hold and the start date(normally today)
  2. the # of holidays that occurred between the 2 dates span
  3. and finally add the # of business days to the original promise date to get the new promise date.

The application should also verify that the new promise date itself is not a holiday and make adjustments as necessary.

I am very grateful to Lucas Smith for his elegant addBusinessDays function. This is far more efficient that what I came up with.

function addBusinessDays(d,n) {
 d = new Date(d.getTime());
var day = d.getDay();
 d.getDate() + n +
 (day === 6 ? 2 : +!day) +
 (Math.floor((n - 1 + (day % 6 || 1)) / 5) * 2));
return d;


After a few days of work I was able to put together a functional calculator. I spent another 2 days fixing a bug in Internet Explorer 8. This is the current deployed version. Its much more faster and convenient than the Microsoft Access behemoth I had everyone using before.

Promise Date Calculator

Currently the 9 holidays are manually entered in an array and will need to be updated each year for the calculator to work. My todo list for this project is to dynamically calculate the 9 holidays so the application can be self contained without needing someone to do the yearly maintenance  to update the holidays.

Download  source code via CodeProject

Vermont 100 DNF

I had my first DNF at a race this past weekend. I attempted the Vermont 100 and dropped at mile 62.5

A lot of things went wrong. I was ill prepared and inadequately trained. The course wasn’t very technical but the hills were relentless.

I did not train on enough hills. The one key aspect of 100s are night running and I neglected to cover this during my training. Once the sun went down I broke down mentally and was looking for any excuse to quit.

I needed a crew. The mental support they provide would’ve helped me pushed on when I have doubts.

I need to pay a lot more attention to what I put in my dropbags. Most of the things I had in there I couldn’t use at all.

My unraveling was in part caused by my taking of the 5 hour energy bottles. I used it during my 5 hour training runs on weekends and figured that it would help during the actual race. After downing 6 of them the appetite suppressant side effect did a number on me and I was no longer able to consume any food. I didn’t want to eat or drink anything.

5 hour energy and ginger ale doesn’t mix well together. I threw up as soon as I drank a cup of ginger ale.

By mile 54 I was losing too much weigh and couldn’t consume any food to maintain a safe weight. I would not have passed the upcoming weigh check stations.

I tried to forcefully cram sandwiches and fruits down my throat but everything came back out. At mile 57.4 it got dark and I only had on a singlet. I was walking a lot so I wasn’t able to generate enough body heat to keep myself warm. I was freezing. I didn’t pack any warm clothes in my drop bags.

I slogged my way to the next aid station at 62.5 They had a fire going, I told them I needed to sit for a bit to warm myself up. I pulled a chair up right next to the fire and sat there. After about 15 minutes one of the sweepers came up to me and asked if I wanted to quit and pointed me to the van of shame. Another 15 minute went by and I finally broke down. I told him I was done.

I learned a lot on how to approach a 100 mile foot race. I made some poor decisions regarding my training and nutrition. The best lessons are learned through personal mistakes. The experience made me a bit wiser. I will make the necessary adjustments the next time around. I hate to leave unfinished business.