Forum Discussion

upiotrowska's avatar
upiotrowska
Regular Visitor
2 years ago

Add column with a dynamic values

Hello, 

I have two tabled dim_company with company_id, company_name....

and fact_company with company_id, date and metrics like eg visits.

 

I need to add a column in the dim table with a ranking by number of visits. So company with the highest number of visits should be 1, ect. When I change values in a date slicer on a dashboard I want the values in Rank column to change accordingly and take into account only sum of visits within a given time rane.

 

How can I create this column?

 

Best