Implemented Where clause functionality