added an api that returns work records having indexed date less than equal to queried date