Fixed missing FROM statement.
Fixed filter bug.
Fixed filter bug when target is empty.