How do I display simple row number for each row in quicksight pivot table visual?

How do I display simple row number for each row in quicksight pivot table visual?

Hello @HenryQS - Welcome to the Community! Thanks for posting your query. There’s no out of the box way to do this in QuickSight. I believe, when you say that you would like to add row number in pivot table as rows that means it has to be a dimension and can’t have custom aggregate levels. However, please take a look at the following link and see if this helps! Thankyou!


Thanks for your reply. The solution seems to what I was looking for, except for the fact that out of N number of columns, I don’t have anything in those columns that can be ranked. So the concat String really has not meaningful columns to choose from.
What I want is simply to have the row number of the table to be listed from 1 to the number of rows in the table (A simple table visual as opposed to pivot table would be acceptable as well).
I’m just surprised that Quicksight doesn’t have the simplest thing to simply list the row index of unordered table. The purpose is for anyone looking at the table to be able to refer to which line/row the information we are referring to in the table and the total number of row count at the end of the table itself

@HenryQS - In that case, can you try to create a calculated field using the runningCount function to see if an expression can be created to get this done. It could be something like :

runningCount(, [1 ASC], )

Note : You can go through the documentation to see different options to play around with it.

Let me know if this helps!


Thank you sagmukhe.
the runningCount somewhat works but can only be used on the right part of the field wells (i.e. value)… From the perspective of a simple table, having the row count in the middle of a table looks a bit strange… but it is certainly better than nothing. Again, thanks for the response.

1 Like

Hi @HenryQS, you mentioned that a table visual (instead of pivot table) would also work for you. When using a table visual, you can also move the measure column that is linked to the calculated field to the complete left side of the table. This can be achieved by clicking on the header of the column and selecting the left arrow symbol at the menu option “Move”. Hope this helps.

1 Like