Abstract: Call one of the attached transformations as a subtransformation in your main transformation to calculate Easter sunday for any give year in the Gregorian calendar. From there you can easily calculate a host of widely observed christian holidays. This may be useful for loading holiday attributes in a date dimension.
Authors: Roland Bouman, Matt Casters
Kettle versions: 3.2.0 and up (see Attachments section for more detailed info)
- test_calculate_easter_day.ktr - Transformation that illustrates how to use the easter day calculation transformations in your own transformation.
For a wide range of use cases, a date dimension that keeps track of holidays is a valuable asset. Many countries observe Christian holidays, so it would be really nice to have a generic solution to pre-calculate all Christian holidays.
The most well known Christian holidays are Christmas and Easter. Keeping track of Christmas is trivial, as Christmas day (and thus, Christmas eve) occur always on the same date. Easter on the other hand does not occur on the same date. In addition to Easter itself, there are a number of holidays that occur at a fixed number of days before and after Easter, such as:
- Good Friday (2 days before Easter)
- Maundy Thursday (3 days before Easter)
- Holy Wednesday (4 days before Easter)
- Palm Sunday (7 days before Easter)
- Ascension (40 days after Easter)
- Pentecost (50 days after Easter)
The list is not exhaustive. Days like Trinity Sunday, Corpus Christi, Ash Wednesday are also related via a fixed interval to Easter sunday.
There are a number of algorithms available tot calculate Easter sunday. For more general information on the subject, see: http://en.wikipedia.org/wiki/Computus