Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a table on my dashboard which contains the count of times it appears in the entire table
page | click | % |
page1 | 2 | |
page2 | 1 | |
page3 | 5 | |
page4 | 7 |
I want to calculate the percentage based off the total amount of pages in my table. I am able to get the click column by simply doing `count(page)` on my click column, but I am having a hard time getting the percentage. This would be each click value for everypage divided by total clicks.
My logic says count(page)/sum(count(page)) but i am getting a aggregate nesting error
I made a mistake when writing the question, its actually count(pages) which is not a numeric type 😞 so i dont think that will work . i just made an edit
Try this:
count(clicks)/count(total clicks)
I made a mistake when writing the question, its actually count(pages) which is not a numeric type 😞 so i dont think that will work . i just made an edit
count(total pages) would work also as denominator, doesn't need to be numeric.
it worked! thanks