BUG: fix HDFStore iterator to handle a where properly (GH8014)

closes #8014