fix tablescan, added date