> ## Documentation Index
> Fetch the complete documentation index at: https://docs.datazone.co/llms.txt
> Use this file to discover all available pages before exploring further.

# SAP BW

> Connect to SAP Business Warehouse InfoProviders via the Datazone CloudFeed SAP Connector.

# Overview

SAP BW (Business Warehouse) is SAP's data warehousing platform, where business data is modelled into **InfoProviders** — InfoCubes, DataStore Objects, and CompositeProviders. Datazone connects to SAP BW via the **Datazone CloudFeed SAP Connector**, an HTTP adapter installed on your SAP system, and extracts InfoProviders rather than transparent tables.

## Prerequisites

The **Datazone CloudFeed SAP Connector** must be installed on your SAP environment before creating this source. Contact your SAP administrator to confirm the connector is active.

## Connection Parameters

Set on the source when you create it. Names match the API and CLI payload.

<ParamField path="name" type="string" required>
  **Name** — a unique identifier for your SAP BW source.
</ParamField>

<ParamField path="base_url" type="string" required>
  **Base URL** — base URL of the SAP system running the CloudFeed connector, for example `https://your-bw-host:8080`.
</ParamField>

<ParamField path="username" type="string" required>
  **Username** — SAP technical user username.
</ParamField>

<ParamField path="password" type="string" required>
  **Password** — password for the specified user. Stored encrypted.
</ParamField>

## Extract Parameters

Set per extract, in `source_parameters`. See [Shared Extract Parameters](/reference/sources/overview#shared-extract-parameters) for `mode`, `replication_key`, and `schema_mapping`.

<ParamField path="table_name" type="string" required>
  **InfoProvider Name** — the InfoProvider to extract, for example `0MATERIAL`.
</ParamField>

<ParamField path="package_size" type="integer" default="50000">
  Rows SAP puts in each extraction package. Packages are streamed rather than buffered whole, so this bounds peak memory. Lower it for very wide objects.
</ParamField>

<ParamField path="batch_size" type="integer" default="50000">
  Rows written per batch on the Datazone side.
</ParamField>

<ParamField path="parallel_fetch" type="boolean" default="true">
  Fetch ready packages concurrently instead of one at a time. Turn it off to minimise load on the SAP system.
</ParamField>

<ParamField path="parallel_task_count" type="integer" default="4">
  Number of concurrent package fetches when `parallel_fetch` is on. Peak memory scales with this multiplied by `package_size`, so raise the two together with care.
</ParamField>

<ParamField path="timeout" type="integer" default="60">
  Per-request timeout in seconds when talking to the CloudFeed connector.
</ParamField>

<ParamField path="filters" type="object[]">
  SAP range-table filters, evaluated inside SAP before any data leaves the system. Each entry takes `FIELDNAME`, `SIGN` (`I` to include, `E` to exclude), `OPTION` (`EQ`, `NE`, `GT`, `GE`, `LT`, `LE`, `BT`, `CP`), `LOW`, and `HIGH` (upper bound, for `BT`).

  ```json theme={null}
  [{ "FIELDNAME": "MTART", "SIGN": "I", "OPTION": "EQ", "LOW": "FERT", "HIGH": "" }]
  ```
</ParamField>

<ParamField path="delta_settings" type="object">
  Delta configuration, **required** when `mode` is `append`. Delta state is held server-side by SAP against `ID`, not tracked by Datazone, and is committed only after the extraction succeeds.

  ```json theme={null}
  {
    "ID": "unique-extraction-id",
    "TYPE": "MULTI",
    "OPERATOR": "GE",
    "COLUMNS": ["LAEDA"]
  }
  ```

  `ID` identifies the delta stream and must stay stable across runs; `TYPE` is `SINGLE` or `MULTI` column; `OPERATOR` is the comparison applied to `COLUMNS`.
</ParamField>

<ParamField path="select_clause" type="string" default="*">
  Columns to read, as a comma-separated list.
</ParamField>

<ParamField path="filter_clause" type="string">
  Row filter applied to the extracted rows, written without the `WHERE` keyword. For filtering inside SAP, prefer `filters`.
</ParamField>

<Note>
  `extraction_timeout` (default 7200 seconds) and `check_interval` (default 5 seconds) govern how long Datazone waits for SAP to finish an extraction job and how often it polls. Neither is read from `source_parameters` — set them through the extract's `custom_reader_config` if you need to change them.
</Note>

## Required Permissions

Assign the following roles to the SAP technical user:

| Role                 | Description                 |
| -------------------- | --------------------------- |
| `/CLF/BASE`          | CloudFeed Base Service Role |
| `/CLF/TABLE_ALL`     | All Table Access            |
| `/CLF/WRITEBACK_ALL` | All Writeback Access        |

## How It Works

Datazone requests an extraction job from the CloudFeed connector, polls it until packages become ready, and streams each package as it arrives. On success the extraction is committed, which advances the server-side delta state for `append` extracts.

## SAP ERP vs SAP BW

Both connectors speak to the same CloudFeed connector and share their filter syntax, delta settings, package streaming, and commit-on-success behaviour. They differ in what they read:

|                        | SAP ERP                          | SAP BW                               |
| ---------------------- | -------------------------------- | ------------------------------------ |
| **Extraction target**  | Transparent tables (e.g. `MARA`) | InfoProviders (e.g. `0MATERIAL`)     |
| **CloudFeed endpoint** | `/sap/cloudfeed/module/table`    | `/sap/cloudfeed/module/infoprovider` |
| **Use case**           | Raw operational tables           | Modelled, aggregated warehouse data  |

## Limitations

* Maximum payload size per request: 10 MB
* `delta_settings` is required for `append` extracts; without it, incremental extraction has nothing to track
* Delta state lives in SAP, so resetting an extract's position is done on the SAP side against the `delta_settings.ID`

## Next Steps

1. Create extracts to specify which InfoProviders to ingest
2. Configure scheduling for recurring extracts
3. Integrate the source into your data pipelines
