Skip to content

Issue with FILTER_GROUP (RangeError: Maximum call stack size exceeded) #9173

Open
@itestyoy

Description

@itestyoy

Hi! When we use FILTER_GROUP in measures, we get a RangeError: Maximum call stack size exceeded.

Model:

 cube(`test`, {
        sql: `select 1 as value, '1' as name`,

        measures: {
            metric: {
                sql: `value`,
                type: `avg`,
                filters: [
                    { sql: `${CUBE}.name = ${FILTER_GROUP(FILTER_PARAMS.test.name.filter((kpi) => kpi))}` }
                ],
            },
        },

        dimensions: {
            name: {
                sql: `name`,
                type: `string`
            },
            value: {
                sql: `value`,
                type: `number`
            }
        },
    });

Query:

{
  "dimensions": [
    "test.name",
    "test.value"
  ],
  "measures": [
    "test.metric"
  ],
  "filters": [
    {
      "values": [
        "1"
      ],
      "member": "test.name",
      "operator": "equals"
    }
  ]
}

Without FILTER_GROUP with FILTER_PARAMS... AND FILTER_PARAMS... .... works fine.

Metadata

Metadata

Assignees

Labels

questionThe issue is a question. Please use Stack Overflow for questions.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions