Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hello, i am new to PBI , and i have the next situation,
i have 2 tables that look like:
id | created_at |
and
id | price | expired_at |
for each id in first table, i have multiple entry in the second table,
i want to add to the first table a field price in which i have the price from the second table, which was active at the created moment.
Thank you
Hi @cristianj ,
Is it possible to provide screenshots of test data and desired results?
How to Get Your Question Answered Quickly - Microsoft Power BI Community
Best Regards,
Henry
Hi @cristianj ,
According to your description, you can use "make this relationship inactive" for both tables, and then use the USERELATIONSHIP function to count the total value corresponding to the id field.
Measure = CALCULATE(SUM(Table2[Value]),USERELATIONSHIP(Table1[ID],Table2[ID]))
If the problem is still not resolved, please provide detailed error information and let me know immediately. Looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hello
i did not find the answer
First table in which i want to get the price from the second contains the id and the moment of the order,
and in the second i have the id, the price and one more column named expired_at (which says till that moment the price was valid), i want to every lines from the first to get the price which was valid at the moment i made the order in 1 table so i want to get from table 2 the last record which expired_at is smaller then the expired_At value
User | Count |
---|---|
98 | |
76 | |
74 | |
49 | |
26 |