Forum Discussion
Division with a Filter
Create a date table linked to both Table1 and Table2. Use the year / month column from the date table on your visual and your existing measure should work fine.
Apologies if I'm misunderstanding, I'm still fairly new to PowerBI.
This is all still in the Data tab and it is a column that I'm creating, not a measure. Is the auto date/time setting not sufficient for this?
The result I'm getting is 532% in the Percentage column because it is counting ALL IPs in Table 1 and dividing it by the count of IPs in Table 2.
- johnt754 years ago
Super User
Is the column going on the table with the IP addresses or the hostnames. And do both tables have a month column?
- austinjgreer4 years agoFrequent Visitor
The column is going into Table 1. Table 2 is a static list of ~6500 IPs/hostnames that does not change and has no dates on it.
- johnt754 years ago
Super User
try
Percentage = DIVIDE( CALCULATE( COUNTROWS('Table1'), ALLEXCEPT( 'Table1', 'Table1'[IP Address], 'Table1[Month]) ), COUNTROWS('Table2') )