Data Prep Quicksight calculations or Athena SQL query calculations, Which is better?

I have some calculated fields done in the analyses section and I feel that it is impacting the performance, hence i am trying to move some of these calculations either to data prep or Athena queries.

I also recently had an experience when i moved a big ‘if else’ calculation to data prep in order to utilise that field in filters, however, it takes a few more seconds to load this filter compared to other filters though the dataset was in spice.

So i am trying to figure out, placing the calculation in athena query or having calculated fields in data prep is better for optimizing the dashboard. I would like to have this advice for both spice and direct query datasets. Appreciate your suggestions🙂

Hi @lalprasanth - In case of of direct query, it is better to do the calculation at athena level and ready with the data and then do the reporting in QuickSight. In case of SPICE, possibly better option will be do the calculation at QuickSight level.

Let’s hear from other experts as well.

Hi @David_Wong @Max @Koushik_Muthanna @Karthik_Tharmarajan @Naveed - Please share your opinion on this.

Regards - Sanjeeb

2 Likes

Hi, @lalprasanth I agreed with you Calculation at Analysis level took some time these should be at SPICE level but you are using the the Direct query mode so my opinion is to use at Athena level if you already using it. Direct Query will do the caculate each time as user change ay filter etc. It hits will be cost all the time as query run.

@Sanjeeb2022 already shared both options. :slight_smile:
Regards,
Naveed Ali

1 Like

Hey @lalprasanth

We have not heard back from you regarding your question. We would still like to help. If we do not hear back in the next 3 days, we will archive the question.

@Sanjeeb2022 @Naveed @Max For the direct query, moving those calculations to glue makes it a more faster compared to having them in the query or data prep. For spice its the same speed even if you moved the calculation to glue or dataprep

But spice engine struggles with the text search box. Don’t have problem when it has to search on less data but have problem when it searches on 10gb or more than that(in this large data search scenario, athena direct query is way better)

2 Likes