Validate Formula

LLM-friendly URL
POST
https://api.luzmo.com/0.1.0/formula
API call form
Examples

Validates formula against syntax and logical errors.

We support following functions in expression:

  • AVG({<dataset_ID>:<column_ID>})

  • COUNT({<dataset_ID>:<column_ID>})

  • COUNTD({<dataset_ID>:<column_ID>})

  • COUNTR()

  • MAX({<dataset_ID>:<column_ID>})

  • MIN({<dataset_ID>:<column_ID>})

  • SUM({<dataset_ID>:<column_ID>})

Derived column expressions can be combined with these aggregators. See this Academy article for the available operators.

Use GROUPFULL(aggregation) to ignore chart dimensions (filters still apply). Use GROUPINEX(aggregation, [columns to group by], [columns to exclude]) to include or exclude grouping columns. Nested aggregations wrap an inner grouped aggregation, for example AVG(GROUPINEX(SUM(...), [{<dataset_ID>:<column_ID>}], [])) . See Aggregation formulas .

Example:

"expression": "COUNTD({<orders_dataset_id>:<order_id_column_id>}) / COUNTD({<orders_dataset_id>:<store_id_column_id>})"

Filtering formula results: When querying data, use a having filter to keep groups whose calculated formula result meets a condition, such as a rate above a target or a score below a threshold. These filters apply after aggregation and grouping. See Having filters .

Request parametersResponse schema
Expand all Reset
properties *OBJECTrequired
expression *STRINGrequired
Can be executed by:
Logged-in User
Can be associated to:
Currency
Dataset
User
Tenants
Did this page help you?
Yes No
Language
Shell
Node
Java
.NET
Python
PHP
Install
npm install @luzmo/nodejs-sdk
Example Response
200
400
500
{
  "type": "numeric",
  "valid": true
}