---
schema_version: "1"
id: 0bd8fd8083feba6f9f05d2bb8447c18644749cd1894c9679ab15c1fd35d8d7dc
title: OData 4.0 and 4.01 Query Options
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/platform/264-0-0/odata_considerations_search_v4.md
canonical_url: https://help.salesforce.com/s/articleView?id=platform.odata_considerations_search_v4.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 6f74e92c0a0ec55bf8e48a18d3ae14ce444055c368fbf457d133c1aa92f84fe4
description: By default, the search query string is used as the contains value in the $filter system query option.
products:
  - Salesforce Platform
  - Security
release: "264"
---
# OData 4.0 and 4.01 Query Options

By default, the search query string is used as the `contains` value in the `$filter` system query option.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition">
      <colgroup>
        <col>
      </colgroup>
      <tbody>
        <tr class="">
          <td class="slds-cell-wrap" style="vertical-align:top;">Available in: both Salesforce Classic and Lightning Experience (not for high-data-volume
            external objects)</td>

        </tr>
        <tr class="">
          <td class="slds-cell-wrap" style="vertical-align:top;">
            <p>Available in: <strong>Developer</strong> Edition</p>
            <p style="margin-bottom:0;">Available for an extra cost
              in: <strong>Enterprise</strong>, <strong>Performance</strong>, and <strong>Unlimited</strong>
              Editions</p>
          </td>

        </tr>
      </tbody>
    </table>

In the following example, the search query string is Acme.

```
http://services.example.org/v4.svc/Shippers?
$select=CompanyName,Phone,ShipperID&$count=true&
$filter=contains(CompanyName,'Acme') eq true 
or contains(Phone,'Acme') eq true$top=25&
```

## OData 4.0 and 4.01 Custom Query Option

We recommend that you set up the OData producer to support free text search expressions with the `$search` system query option. You can then select Use Free-Text Search Expressions on the external data source.

```
http://services.example.org/v4.svc/Shippers?
$select=CompanyName,Phone,ShipperID&$count=true&
$search=Acme&$top=25
```

[http://www.odata.org](http://www.odata.org)