Forum Discussion
Manage indirect relationship: DAX USERELATIONSHIP
I have these tables:
- Orders
| id | user_id | wallet_id |
- Users
| id | name | wallet_id |
- Wallet
| id | balance |
I can make a relationship between Users and Wallet and Orders and Wallet but when I try to make a relationship between Orders and Users I get a message there already is a indirect relationship.
I would like to put on a visual this:
| Order (id) | user (name) | wallet (balance) |
but I cannot get a connection between Order and user so I'm using DAX
USERELATIONSHIP(Orders[user_id], Users[id])
but I know this doesn't simply work. I must put this inside another DAX.
I tried
CALCULATE(MAX(name), USERELATIONSHIP(Orders[user_id], Users[id]))
but I only get one name with Z (the last on alphabetic order).
Can anyone help me?
1 Reply
- V-lianl-msft
Community Support
I tried to create a model as you described. Everything is normal. I can create a relationship between orders and users.
If the problem persists, please provide a sample pbix after deleting sensitive data.