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!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I am trying to use data from table ProjetoSegmento(2) and ProjetoSegmentoOrcamento in table ProjectoSegmento using function Related. But it doesn't work.
But I don't understand why since they are both related to it.
That is going to depend on a whole raft of things like what specifically you are trying to accomplish. Some things that you can try, you can check out USERELATIONSHIP and perhaps you are running into a scenario where the cross-filtering is causing you issues, you could try to make the relationships filter in only one direction. If you could provide some data (text) and specifically what you are trying to achieve, that would help tremendously.
So tabele ProjetoSegmento(2) is a duplicate of ProjetoSegmento because I need to create a column with all the dates between two sets of dates related to the beginning and end of a project. So I used Number.from[stardate]..Number.from[enddate] and created column [diasdeprojeto], since each project has several days I them had to expand the list and got a table with ProjetoSegmentoID repetead. and know I need to get the column [quant] in table ProjetoSegmento(2), using the relationship [id] in table projectoSegmento(2) (which is repeat) with [ProjectSegmentoId] in table ProjetoSegmentoOrcamento. Both tables are linked to ProjetosSegmento which has the primary informations.
Was I clear?
Hi @inescosta,
Thanks for your detail description. If there is one to many relation table A(one) and table B(many), you only use related function in table B which have multiple values. If you used related in table A direction, it will return error. Because it doesn’t verify which one should be return.
>> So tabele ProjetoSegmento(2) is a duplicate of ProjetoSegmento because I need to create a column with all the dates between two sets of dates related to the beginning and end of a project. So I used Number.from[stardate]..Number.from[enddate] and created column [diasdeprojeto], since each project has several days I them had to expand the list and got a table with ProjetoSegmentoID repetead.
You should count the days in ‘ProjetoSegmentoOrcamento’ table for each ID. Then summarize it using appropriate function based on your requirement in ‘ProjetoSegmento(2)’ table. Finally, you can used related function in ‘ProjetoSegmento’ table to get the result.
If this is not what you want, please share the sample data and expected result for further analysis.
Best Regards,
Angelia
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 40 | |
| 35 | |
| 34 | |
| 31 | |
| 28 |
| User | Count |
|---|---|
| 137 | |
| 102 | |
| 71 | |
| 67 | |
| 65 |