Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi all,
i'm newbie with DAX so your help would be really great.
I have two tables:
TableA: Energy Readings table (once a day I record total Energy consumption per energy counter). Columns: ReadingDate, CounterID, Energy
and than I have the Clients Table. Each client may have one or several counters associated (depends on room size...) and StartDate and EndDate. In this Table i'll keep record of old clients (to historize energy consumption), so the relation between this two tables is many-to-many:
...My problem here is that i need to keep track of the energy consumption by client.
My idea was to add a new Column to ReadingsTable with the actual client related to the reading date.
It would be something like this:
..any ideas on how to have the new column? The logic would be to add Client name with the related client from Client table according to the dates.
Thank you in advance!
Solved! Go to Solution.
Hi @filipe,
It seems the Date and the CounterID can determine a unique row. I would suggest you add such a column. No matter who is using that room, the history can be tracked. It could be like below.
ID = FORMAT ( [ReadingDate], "YYYYMMDD" ) & [CounterID]
Best Regards,
Hi @filipe,
It seems the Date and the CounterID can determine a unique row. I would suggest you add such a column. No matter who is using that room, the history can be tracked. It could be like below.
ID = FORMAT ( [ReadingDate], "YYYYMMDD" ) & [CounterID]
Best Regards,
Thank you very much!
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
99 | |
77 | |
66 | |
54 |
User | Count |
---|---|
144 | |
104 | |
102 | |
87 | |
64 |