I have been boggling my head on the table over the past few days, and therefore I am addressing you, the stack overflow.
The software I'm working on has time sensitive data. The usual solution for this is effective and expiration date.
EFF_DT XPIR_DT VALUE
2000-05-01 2000-10-31 100
2000-11-01 (null) 90
That would be easy. Unfortunately, we need data that is repeated on an annual basis arbitrarily far into the future. In other words, every May 1 (starting in 2000) we may need an effective value of 100, and every November 1 we can change it to 90.
This may be true for a long time (> 50 years), and therefore I do not want to just create a hundred records. I do not want to do this:
EFF_DT XPIR_DT VALUE
2000-05-01 2000-10-31 100
2000-11-01 2001-04-30 90
2001-05-01 2001-10-31 100
2001-11-01 2002-04-30 90
2002-05-01 2002-10-31 100
2002-11-01 2003-04-30 90
...
2049-05-01 2049-10-31 100
2049-11-01 2050-04-30 90
2050-05-01 2050-10-31 100
2050-11-01 2051-04-30 90
. 2000 ( -), :
EFF_DT XPIR_DT REPEATABLE VALUE
1995-01-01 2000-04-30 false 85
2000-05-01 2010-04-30 true 100
2000-11-01 2010-10-31 true 90
2010-05-01 (null) true 120
2010-11-01 (null) true 115
( ), , , , .
: , 2010-03-09?
, - ( ), , .
EFF_DT MOST_RECENT XPIR_DT VALUE
2000-05-01 2009-05-01 2010-04-30 100
2000-11-01 2009-11-01 2010-10-31 90
90, 2009-11-01 2009-05-01.
., , 2007-06-20:
EFF_DT MOST_RECENT XPIR_DT VALUE
2000-05-01 2007-05-01 2010-04-30 100
2000-11-01 2006-11-01 2010-10-31 90
100, 2007-05-01 2006-11-01.
MySQL, MOST_RECENT?
- ?
- Java, . !