Qlik Community

Qlik Sense EA Powertools

Discussion board where members can learn more about Qlik Sense Powertools.

Announcements
BARC’s The BI Survey 19 makes it official. BI users love Qlik. GET REPORT
Highlighted
excelimpact_com
New Contributor

Calculated dimensions

I am trying to create a calculated dimension from an excel file. The MetricFormula is as follows:

IF("Field Name"='My value', 1, 0)

The issue I'm facing is that once imported it says:

[IF("Field Name"='My value', 1, 0)] which is interpreted as a field name, rather than an expression. Any ideas how I can fix this problem?

5 Replies

Re: Calculated dimensions

May be add AS FieldName

IF("Field Name"='My value', 1, 0) as NewFieldName

Re: Calculated dimensions

I think you are doing this in the script. Would you be able to share a screenshot of the issue?

excelimpact_com
New Contributor

Re: Calculated dimensions

No Sunny, I'm using the Governed Metrics to put the formula as described above in an Excel File, and them I'm importing them using the Governed Metrics extension; however, when I import the formula, the brackets appear around the formula.

Not applicable

Re: Calculated dimensions

Rodolfo, I have a feeling this may be a current limitation in GMS.  When I coded dimensions I think I'm populating field list only and not allowing for calculated dimensions which would stick the formula somewhere else in the definition.

I recommend opening an issue on Github here: Issues · eapowertools/GovernedMetricsService · GitHub

and I'll add it to the list of addressables.  Expect an update of GMS in mid to end of January.

Jeff G

excelimpact_com
New Contributor

Re: Calculated dimensions

Issue created. Thanks Jeff.