title: How to remove empty values in drop down using ng-option in angular js?
body: <ul>
  <li>How to remove empty and blank values in the <code>Drop Down</code> using ng-option in angular js?</li>
  <li>Some data's are in <code>college name</code> some of it not having the <code>college name</code> so what is happening in the drop down, the empty values are displaying.</li>
  <li><p>I am expecting only values, not empty blank items, so how to remove empty items.</p></li>
  <li><p><a href="http://plnkr.co/edit/Po6pV7BNvX7Rw02sMejG?p=preview" rel="nofollow noreferrer">My Plunker</a>.</p></li>
  <li><p>And how to <code>Mingle</code> <code>College Name</code> and <code>School Name</code> into a single <code>Drop Down</code>.</p></li>
  </ul>
  
  <p><strong>My Drop Down:-</strong></p>
  
  <pre><code>&lt;select data-ng-model="searchtable.college_name" id="searchtable" ng-options="item.college_name as item.college_name for item in users" class="form-control" placeholder="search" required&gt;&lt;option value=""&gt;All&lt;/option&gt;&lt;/select&gt;
  
    &lt;label for=""&gt;school name&lt;/label&gt;
         &lt;select data-ng-model="searchtable.school_name" id="searchtable" ng-options="item.school_name as item.school_name for item in users" class="form-control" placeholder="search" required&gt;&lt;option value=""&gt;All&lt;/option&gt;&lt;/select&gt;
  </code></pre>
  
  <p><strong>My Html:-</strong></p>
  
  <pre><code>&lt;div class="col-md-3"&gt;
      &lt;label for=""&gt;College name&lt;/label&gt;
      &lt;select data-ng-model="searchtable.college_name" id="searchtable" ng-options="item.college_name as item.college_name for item in users" class="form-control" placeholder="search" required&gt;
          &lt;option value=""&gt;All&lt;/option&gt;
      &lt;/select&gt;
      &lt;label for=""&gt;school name&lt;/label&gt;
      &lt;select data-ng-model="searchtable.school_name" id="searchtable" ng-options="item.school_name as item.school_name for item in users" class="form-control" placeholder="search" required&gt;
          &lt;option value=""&gt;All&lt;/option&gt;
      &lt;/select&gt;
      &lt;div ng-repeat="question in users | filter: searchtable | filter: myrole"&gt; &lt;small&gt;
                    &lt;table border="0"&gt;
                      &lt;tbody&gt;
                        &lt;th&gt;{{question.displayName}}&lt;/th&gt;
                      &lt;th style="background: yellow;"&gt;,{{question.roles[0]}}&lt;/th&gt;
                      &lt;th style="background: light;"&gt;,{{question.request_role[0]}}&lt;/th&gt;
  
                      &lt;/tbody&gt;
                            &lt;/table&gt;
  
  
                    &lt;/small&gt; &lt;/div&gt;
      &lt;p&gt;How to mingle college name and school name into single drop down:-&lt;/p&gt;
      &lt;p&gt;And how to do filter college name and school name while selecting the filed&lt;/p&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p><strong>My Data:-</strong></p>
  
  <pre><code>    $scope.users = [{
  "_id": "59a6c7c96c2ce324124cc1d8",
  "displayName": "blink foundation",
  "provider": "local",
  "location": "icf",
  "username": "blink",
  "dob": "1991-10-04T18:30:00.000Z",
  "phone": 7299345250,
  "religion": "Hindu",
  "college_name": "Arignar Anna",
  "__v": 2,
  "created": "2017-08-30T14:12:25.397Z",
  "roles": [
  "block"
  ],
  "request_role": [
  "Change Agent"
  ],
  "lastName": "foundation",
  "firstName": "blink"
  },
  {
  "_id": "598abfe4cce8ed582a2d8b32",
  "displayName": "avinaash muthukumar",
  "provider": "local",
  "username": "avinaash muthu",
  "__v": 0,
  "created": "2017-08-09T07:55:16.511Z",
  "roles": [
  "admin"
  ],
  "request_role": ["Change Agent"],
  "firstName": "avinaash"
  },
  {
  "_id": "5979a591c999e9302caece13",
  "displayName": "Ajmal Afthab",
  "provider": "local",
  "location": "Urapakkam",
  "username": "ajmal_afthab",
  "dob": "1995-01-23T18:30:00.000Z",
  "phone": 9500269131,
  "religion": "Islam",
  "school_name": "public school",
  "__v": 1,
  "roles": [
  "kp"
  ],
  "request_role": ["school student"],
  "categories": [
  "Religion &amp; Culture",
  "Moral Ethics",
  "Social Psychology"
  ],
  "lastName": "Afthab",
  "firstName": "Ajmal"
  },
  {
  "_id": "5978a2886d5b10ec321a2114",
  "displayName": "happy selvam",
  "provider": "local",
  "username": "happy",
  "__v": 0,
  "created": "2017-07-26T14:09:12.730Z",
  "roles": [
  "admin"
  ],
  "request_role": ["parent"],
  "categories": [],
  "lastName": "selvam",
  "firstName": "happy"
  },
  {
  "_id": "58e73c5c9e2f3f1421e241be",
  "displayName": "sarawana kumar",
  "religion": "hindu",
  "college_name": "IIT",
  "__v": 2,
  "roles": [
  "user"
  ],
  "request_role": ["school student"],
  "categories": [
  "Religion &amp; Culture",
  "Social Psychology"
  ],
  "lastName": "kumar",
  "firstName": "sarawana"
  },
  {
  "_id": "58d0fab62758cc482c295eba",
  "displayName": "avinaash kumaran",
  "provider": "local",
  "username": "avinaash",
  "roles": [
  "block"
  ],
  "request_role": ["parent"],
  "categories": [],
  "lastName": "kumaran",
  "firstName": "avinaash"
  },
      ]
  </code></pre>