Model and queries for estimation of all time revenues till 2014-06-30 and later on 2013-12-31