not clean ! 

same as extract until period but with double condition on date
will be joined with extractuntildate.py once we are done