Forum Discussion
Text value from a column to filter another table
- 6 years ago
You can not need the inactive relationship at all if your use an approach using TREATAS() as follows:
Total Value =
VAR __qty =
SUM ( Production[Produced Quantity] )
VAR __metalvalue =
CALCULATE (
MIN ( MetalValues[Value] ),
TREATAS ( VALUES ( Production[Date] ), MetalValues[Date] ),
TREATAS ( VALUES ( Production[Metal] ), MetalValues[Metal] )
)
RETURN
__qty * __metalvalueOr you could use USERELATIONSHIP for the date and just use TREATAS() on metal column. Note: this assumes you are using the columns from Production in your visuals (for Metal and Date).
If this works for you, please mark it as solution. Kudos are appreciated too. Please let me know if not.
Regards,
Pat
You can not need the inactive relationship at all if your use an approach using TREATAS() as follows:
Total Value =
VAR __qty =
SUM ( Production[Produced Quantity] )
VAR __metalvalue =
CALCULATE (
MIN ( MetalValues[Value] ),
TREATAS ( VALUES ( Production[Date] ), MetalValues[Date] ),
TREATAS ( VALUES ( Production[Metal] ), MetalValues[Metal] )
)
RETURN
__qty * __metalvalue
Or you could use USERELATIONSHIP for the date and just use TREATAS() on metal column. Note: this assumes you are using the columns from Production in your visuals (for Metal and Date).
If this works for you, please mark it as solution. Kudos are appreciated too. Please let me know if not.
Regards,
Pat