Get Free Trial
Get Free Trial

Wrong formula format. : 'FIELD' uniqueName is not defined

Answered
Gnanam Raghupathy Naidu asked on August 14, 2019

Hi,
There is a formula defined for the column, earlier version there is no issues when using the field which is not in the data list. But since 2.7.11 I am getting the error as attached. Please check and let know the feasible solution.
 
Thanks,
Gnanam

Attachments:
flex_warning.PNG

3 answers

Public
Ian Sadovy Flexmonster August 14, 2019

Hello,
 
Thank you for the question.
In case you need to disable the warning, please use a special option validateFormulas: false
Here is the sample: https://jsfiddle.net/flexmonster/wsjy05n7/
 
Please note, that the results of formulas with non-existing fields may be unexpected. We strongly recommend excluding such formulas from the reports (and the warning message can help to identify such formulas).
 
Hope you find this helpful.
 
Regards,
Ian

Public
mstrukov November 8, 2019

Hi there,
I ran into the same problem and it seems some characters are not allowed for the uniqueName attribute anymore. We use [Measures].[MEASURENAMEHERE] format for all measures and it works fine with 2.3 version but not with 2.7 (latest). For example,

{
"uniqueName": "[Measures].[Volume]",
"aggregation": "sum",
"caption": "Volume",
"grandTotalCaption": "Volume",
"format": "format1",
"active": true
}

formula – “formula”: “\”[Measures].[AdvertiserSpendInMD]\” / (1000 * \”[Measures].[Volume]\”)
Note, you can easily reproduce it with this example https://jsfiddle.net/flexmonster/x0pe8azg/. Just rename “Price” measure to “[Price]” both in the measure definition and formula.
I’m going to add “validateFormulas”: false but it seems like a bug to me.
 

Public
Vera Didenko Flexmonster 6 days ago

Hello, 
 
Thank you for pointing this out to us.
 
The described behavior is not the expected one: brackets should be allowed in uniqueName properties.
Our team will research this issue in more detail and we will notify you about the results with the ETA 2nd of December.
 
As a temporary solution, we kindly advise disabling the validation pop-up.
 
Please feel free to write to us in case further questions arise.
 
Best Regards,
Vera

Please login or Register to Submit Answer