New to Kendo UI for jQuery? Start a free 30-day trial

Search.fields

configuration

Defines a list of fields which will be included in the search. If values for the property are not defined the grid will search in all column fields.

<div id="grid"></div>
<script>
$("#grid").kendoGrid({
  columns: [
    { field: "name" },
    { field: "age" }
  ],
  dataSource: [ { name: "Jane", age: 30 }, { name: "John", age: 33 }],
  toolbar:["search"],
  search: {
    fields: ["name"] // Or, specify multiple fields by adding them to the array, e.g ["name", "age"]
  }
});
</script>

Defines the name of the field to be included in the search

<div id="grid"></div>
<script>
$("#grid").kendoGrid({
  columns: [
    { field: "name" },
    { field: "age" }
  ],
  dataSource: [ { name: "Jane", age: 30 }, { name: "John", age: 33 }],
  toolbar:["search"],
  search: {
    fields: [ { name: "name" } ]
  }
});
</script>

Defines the operator for the field to be used in the filter expression: filter.

<div id="grid"></div>
<script>
$("#grid").kendoGrid({
  columns: [
    { field: "name" },
    { field: "age" }
  ],
  dataSource: [ { name: "Jane", age: 30 }, { name: "John", age: 33 }],
  toolbar:["search"],
  search: {
    fields: ["name", { name: "age", operator: "eq" }]
  }
});
</script>