title: Angular Js search filter not working
body: <p>I am new to Angular Js and trying to implement the basic search filter feature. Below is my code. But I am not getting expected output. For example, when I type 'fe' into the search box, I am also getting a row that does not have 'fe' text in its columns. What am I missing? Thanks.</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>/// &lt;reference path="angular.js" /&gt;
  
  
  var myModule = angular.module("myModule", [])
      .controller("controllerObj", function ($scope) {
  
          var employees = [
              { name: "Dave", dateOfBirth: new Date(1988, 12, 12), gender: "male", salary: "80000" },
              { name: "Martha", dateOfBirth: new Date(1985, 06, 12), gender: "female", salary: "60000" },
              { name: "Sarah", dateOfBirth: new Date(1970, 12, 3), gender: "female", salary: "75000" },
              { name: "Chris", dateOfBirth: new Date(1960, 7, 8), gender: "male", salary: "110000" },
              { name: "Daniel", dateOfBirth: new Date(1982, 6, 22), gender: "male", salary: "50000" },
              { name: "Micheal", dateOfBirth: new Date(1982, 1, 19), gender: "male", salary: "190000" }
          ];
  
          $scope.employees = employees;
  
          var sortOrder = '+';
  
          var sortColumn = 'name';
  
          $scope.sortExpression = sortOrder + sortColumn;
  
          $scope.sort = function (column) {
              if (column == sortColumn) {
                  sortOrder = (sortOrder == '+') ? '-' : '+';
              }
              else {
                  sortColumn = column;
                  sortOrder = '+';
              }
  
              $scope.sortExpression = sortOrder + sortColumn;
          };
  
  });</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;!DOCTYPE html&gt;
  &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
  &lt;head&gt;
      &lt;title&gt;&lt;/title&gt;
      &lt;script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.7/angular.min.js"&gt;&lt;/script&gt;
      &lt;script src="Scripts/Script.js"&gt;&lt;/script&gt;
  
      &lt;style&gt;
          table {
              border-collapse:collapse;
              
          }
          td {
              border: 1px solid black;
              padding: 5px;
          }
      &lt;/style&gt;
  &lt;/head&gt;
  &lt;body data-ng-app="myModule"&gt;
      &lt;div data-ng-controller="controllerObj"&gt;
          Search: &lt;input type="text" placeholder="Search Employees" ng-model="searchText" /&gt;
          &lt;br /&gt;
          &lt;br /&gt;
          &lt;table&gt;
              &lt;thead&gt;
                  &lt;tr&gt;
                      &lt;td&gt;&lt;a href="#" ng-click="sort('name')"&gt;Name&lt;/a&gt;&lt;/td&gt;
                      &lt;td&gt;&lt;a href="#" ng-click="sort('dateOfBirth')"&gt;Date of Birth&lt;/a&gt;&lt;/td&gt;
                      &lt;td&gt;&lt;a href="#" ng-click="sort('gender')"&gt;Gender&lt;/a&gt;&lt;/td&gt;
                      &lt;td&gt;&lt;a href="#" ng-click="sort('salary')"&gt;Salary&lt;/a&gt;&lt;/td&gt;
                  &lt;/tr&gt;
              &lt;/thead&gt;
              &lt;tbody&gt;
                  &lt;tr ng-repeat="employee in employees | filter : searchText | orderBy : sortExpression"&gt;
                      &lt;td&gt;{{employee.name}}&lt;/td&gt;
                      &lt;td&gt;{{employee.dateOfBirth | date : 'MM/dd/yyyy'}}&lt;/td&gt;
                      &lt;td&gt;{{employee.gender | lowercase}}&lt;/td&gt;
                      &lt;td&gt;{{employee.salary | currency : 'USD$ '}}&lt;/td&gt;
                  &lt;/tr&gt;
              &lt;/tbody&gt;
          &lt;/table&gt;
  
      &lt;/div&gt;
  &lt;/body&gt;
  &lt;/html&gt;</code></pre>
  </div>
  </div>
  </p>