• Preparing search index...
  • The search index is not available
SAP Cloud SDK for JavaScript - v3.26.4
  • SAP Cloud SDK for JavaScript
  • @sap-cloud-sdk/odata-v2
  • replace

Function replace

  • replace<EntityT extends Entity>(
        str:
            | string
            | Field<EntityT, boolean, boolean>
            | StringFilterFunction<EntityT>,
        searchStr:
            | string
            | Field<EntityT, boolean, boolean>
            | StringFilterFunction<EntityT>,
        replaceStr:
            | string
            | Field<EntityT, boolean, boolean>
            | StringFilterFunction<EntityT>,
    ): StringFilterFunction<EntityT>

    Build a filter function to replace the occurrence of a search string with another string. Evaluates to string.

    Type Parameters

    • EntityT extends Entity

    Parameters

    • str: string | Field<EntityT, boolean, boolean> | StringFilterFunction<EntityT>

      The string to get the index from. This can either be a string, a reference to a field or another filter function.

    • searchStr: string | Field<EntityT, boolean, boolean> | StringFilterFunction<EntityT>

      The substring to get the index for. This can either be a string, a reference to a field or another filter function.

    • replaceStr: string | Field<EntityT, boolean, boolean> | StringFilterFunction<EntityT>

      The substring to get the index for. This can either be a string, a reference to a field or another filter function.

    Returns StringFilterFunction<EntityT>

    The newly created filter function.

    Copyright Ⓒ 2025 SAP SE or an SAP affiliate company. All rights reserved.

    • Defined in packages/odata-v2/dist/filter-functions.d.ts:19

Settings

Member Visibility
SAP Cloud SDK for JavaScript - v3.26.4
  • Loading...