Adding missing days for charts

I’ve created a function which adds missing days in an event count overview chart.

Starting dataset

  1. 01/04/2016;”ErrorCode”;10
  2. 03/04/2016;”ErrorCode”;12
  3. 04/04/2016;”ErrorCode”;2
  4. 06/04/2016;”ErrorCode”;32
  5. 07/04/2016;”ErrorCode”;103

After conversion

  1. 01/04/2016;”ErrorCode”;10
  2. 02/04/2016;”ErrorCode”;0
  3. 03/04/2016;”ErrorCode”;12
  4. 04/04/2016;”ErrorCode”;2
  5. 05/04/2016;”ErrorCode”;0
  6. 06/04/2016;”ErrorCode”;32
  7. 07/04/2016;”ErrorCode”;103

Function

AddMissingDays

 

Range is a DateTime Extension, courtesy of StackOverflow.

DateTimeRange

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s