Fixing date search