/api/bigDataSets/tables/:id

This endpoint is used for getting the table defined in the GUI. In case the drillDownConfig is not set, the columns defined via GUI are returned. In case the drillDownConfig parameter is set, the columns defined in the request are returned.

Resource Information

Resource URL

https://service.belladati.com/api/bigDataSets/tables/:id

HTTP Method

GET

Request Parameters

id

ID of the table to fetch. You can find the ID in the response to /api/bigDataSets/:id/tables

123

drilldownConfig

(Optional) (query URL) Replaces the table drill-down with custom configuration.

When ROW_UID is set, indicators aggregation is turned off

If you put any indicator in drilldownConfig, it will overwrite indicators set in table. If no indicator is set in drilldown, an indicator from table will be used.

[
   {
      "dataSetDrilldownAttribute":"ROW_UID"
   },
   {
      "dataSetDrilldownAttribute":"L_CONTINENT"
   },
   {
      "dataSetDrilldownAttribute":"L_CITY"
   },
   {
      "dataSetDrilldownAttribute":"M_VALUE",
      "aggregator":"Sum"
   }
]
filter

(Optional) (query URL) Filter applied to the table, with following structure:


NameDescription
drilldown

Drilldown defined with attribute code and following structure:

NameDescription
opFilter operation type - please see list of supported values.
value/values(Optional) Depends on selected "op". Contains value or values for filter.
countOp

(Optional) Used with COUNT operation. Specifies the second operation used together with count.

Supported values: EQ, NEQ, GT, GTE, LT, LTE

In order to join multiple filters or apply two filters on the same parameter, attribute drilldown can be an array. "conditionType" attribute outside "drilldown" defines condition between drilldown array members and "conditionType" attribute inside drilldown member defines condition between attributes in the drilldown.

{
   "drilldown": {
      "L_COUNTRY_OR_AREA": {
          "op": "EQ",
          "value": "Slovakia"
      },
      "L_TYPE": {
          "op": "IN",
          "values": [ "Type 1", "Type 2", "Type 3" ]
      },
      "L_DATE": {
          "op": "NOT_NULL"
      },
      "L_PRODUCT":{ 
         "op":"COUNT",
         "countOp":"LTE",
         "value":"816"
      }
   }
}

Example of a between filter:
{"drilldown":[{"L_ID":{"op":"GT","value":"10"}},{"L_ID":{"op":"LT","value":"20"}}]} 

size

(Optional) (query URL) Specifies the number of entries on each page if pagination is necessary.

15
offset

(Optional) (query URL) Specifies the page offset if pagination is necessary.

5


Sample Request / Response

Using curl:

curl -H "Authorization: OAuth realm=\"https://service.belladati.com/\", oauth_consumer_key=\"myConsumer\", oauth_token=\"mh7an9dkrg59\", oauth_timestamp=\"135131231\", oauth_nonce=\"randomString\"" https://service.belladati.com/api/bigDataSets/table/5

The JSON format response:

{
  "columns": [
    "l_continent",
    "l_country",
    "l_city",
    "New formula indicator",
    "m_value"
  ],
  "data": [
    [
      "America",
      "Brasil",
      "Sao Paulo",
      "40",
      "4"
    ],
    [
      "Europe",
      "Germany",
      "Hamburg",
      "30",
      "3"
    ]
  ],
  "offset": 0,
  "size": 11,
  "total": 11
}



  • No labels