Forum Discussion
If Statement to Compare Two Values From Different Tables
All,
I am making a table in PBI and have all I need except for one missing piece.
The highlighted event represents a problem that occurs occasionally.
I have the Last Crew field which simply is this the last unitname frim the crew action table:
If that field is blank though, I want to take the Who Completed field listed right beside it.
Does anyone know a dax formula (I'm sure it is some sort of IF statement) to combine those two into one column? I am unsure how the Last option in field wells work, so any insight would be amazing.
Thanks!
If I can provide any more insight, please let me know.
8 Replies
- AnonymousNot applicable
Bump
- Rudy_D
Resolver I
Hi Collin,
Are "Last Crew" and "Who completed" fields from the same table ?
You can simply create une new column with this formula :
New Column = IF(ISBLANK('Table'[Last crew]), 'Table'[Who completed], 'Table'[Last crew])Regards,Rudy- AnonymousNot applicable
They are in two separate tables. The last crew was unitname from the 'Crew Actions' table and Who Completed is from the 'Jobs' table. I am using the Last function on the dropdown to get the last crew, so I am not necessarily sure how to write that in DAX. That is where my confusion is coming from.
- AnonymousNot applicable
I renamed 'unitname' to 'last crew' so end users don't get confused.
- AnonymousNot applicable
They are joined in the model view on event_idx if that provides any additional insight
- AnonymousNot applicable
Hi Anonymous
Has your problem been solved ? If it has been solved, then please consider Accept it as the solution to help the other members find it more quickly.
Best Regard
Community Support Team _ Ailsa Tao