bug fix,add index,improve