Added from date

instead of lag. will fix to datetime now