I'm using Amazon QuickSight and want to create a calculated field which in Tableau would be sum([Field1])/sum([Field2])
. In QuickSight, I attempted sum({Field1})/sum({Field2})
but this did not work ("We encountered an error trying to save your calculated field. Please try creating it again."). Simply doing {Field1}/{Field2}
and then applying the sum aggregation in the visualization stage gives me the incorrect value.
How do I apply a SUM within a calculated field?
In the link Greg posted, Quicksight team answer last year: "Hi All, Calculated fields in analysis are available for data sets that use direct query. SPICE data set support is coming soon.".
I tested it today using spice and it work for me.
I used this formula:
distinct_count(field1) / min(field2)
and then i used it on a pivot table using other field to group data.
It is now possible in Amazon QuickSight. To achieve this you need to add Calculated Field to an Analysis (as described here). There are two types of calculated fields: on a data set level and on on analysis level. You can use aggregations in the analysis level calculated field.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With