Fixed a bug when creating Views with WERE statement.