Forum Discussion
jamuka
6 years agoHelper IV
Divide between two tables
Hello, I want to divide my total sales amount in Sales Table to total visitor number based on location in Visitors Table. Tables have inactive relationship, based on store location (there are two l...
- 6 years ago
Hi jamuka
Since the relationship is inactive, place the fields shown from the Sales table in a table visual and create a measure:
NumVisitors = CALCULATE ( SUM ( VistorsT[Visitor] ), FILTER ( ALL ( VistorsT ), VisitorsT[Store Location] = SELECTEDVALUE ( SalesT[Store Location] ) && VisitorsT[Date] = SELECTEDVALUE ( SalesT[Date] ) ) )This will give you the number of visitors in that location and day. Yo can use that to calculate the quotient as required
Please mark the question solved when done and consider giving kudos if posts are helpful.
Cheers
amitchandak
6 years agoSuper User
jamuka , you should join both tables with Store and then you can analyze data for the store , there you will be able to see both sum of sales and visitor
- jamuka6 years agoHelper IV
Hello amitchandak,
When I join Visitor Table to Store Table and add visitor column to my visual it shows same value (total visitor) for each row instead of location's sum of visitor.