Enable Pre-aggregation Caching

Pre-aggregation tables are stored in the data source. You must therefore ensure that the user has privileges to write into the data source schema that you want to use as a pre-aggregation cache. For more information, refer to the article for the type of database you are using and refer to its User Access Rights section.

To enable pre-aggregation caching, use the /api/v1/entities/dataSources/{dataSourceId} API to set enableCaching to true and set cachePath to the schema where you want your pre-aggregation cache to be stored. Your API call should look like this:

curl -X PATCH $HOST_URL/api/v1/actions/dataSources/<your-data-source> \
-H 'Content-Type: application/vnd.gooddata.api+json' \
-H "Accept: application/json" \
-H 'Authorization: Bearer $API_TOKEN' \
-d '{
  "data": {
    "type": "dataSource",
    "id": "<your-data-source>",
    "attributes": {
      "enableCaching": true,
      "cachePath": [