Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
abelrmg
Helper II
Helper II

Relationship between tables

Hello,

 

I have 4 four tables:

1. Invoicing

2. Date table

3. Accounts receivable

4. Attribute

 

This is the relation:

Relationship.PNG

 

The visualization is this:

visualitation.PNG

The formula Ventas-1 doesn't work when i select a filter for department (LN01,LN02).

 

The formula is:

Ventas-1 = CALCULATE([Ventas]|PARALLELPERIOD(Dates[Date]|-1|month))
 
Ventas = SUM(RMG_AXFACTCUSTINVOICING[LINEAMOUNTMST])
 
The result is this:
Result.PNG
 
Don't show info for Ventas-1 in all months only when the other table have a data. But if a disable the relationship betwen Departamento table with the other transaciont tables works fine.
 
Any ideas how can I do this arrangement?
 
Regards
1 ACCEPTED SOLUTION
abelrmg
Helper II
Helper II

Hello, thanks to everyone the error is this relationship:

 

RELACION.PNG

 

I configured it as a single way and works fine.

 

Regards

 

 

View solution in original post

6 REPLIES 6
abelrmg
Helper II
Helper II

Hello, thanks to everyone the error is this relationship:

 

RELACION.PNG

 

I configured it as a single way and works fine.

 

Regards

 

 

aj1973
Community Champion
Community Champion

good Job

Regards
Amine Jerbi

If I answered your question, please mark this thread as accepted
and you can follow me on
My Website, LinkedIn and Facebook

amitchandak
Super User
Super User

@abelrmg , Try a trailing measure

Ventas-1 = CALCULATE([Ventas],dateadd('Date'[Date],-1,Month))

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

@amitchandak , when I apply the filter for table Departamento usign the forumula  that you proposed to me the visual mark error: the DATEADD function expects continuous selection....

Regards

 

 

aj1973
Community Champion
Community Champion

@abelrmg 

try to make the relationship between tables go both way for all of them and see how it works out!

Regards
Amine Jerbi

If I answered your question, please mark this thread as accepted
and you can follow me on
My Website, LinkedIn and Facebook

@aj1973 , does not allow me to configure relationships in both way it sends an ambiguity error and i should delete a relationship

 

Regards

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.