Date retrieval fix, and historical data fixed