Forum Discussion
Bringing back a LOOKUP value from a table using text field and date ranges
- 4 years ago
Hi, Will_Rayner
You don't need to use .date format in code.
I modify your code, Like this:
SLA Target = MAXX ( FILTER ( ALL ( 'sla' ), [SLA Code] = SELECTEDVALUE ( 'UW Input for SLA'[SLA Type Name] ) && [Effective From] <= SELECTEDVALUE ( 'UW Input for SLA'[END_DATE] ) && [Effective To] >= SELECTEDVALUE ( 'UW Input for SLA'[END_DATE] ) ), [SLA Value] )Did I answer your question ? Please mark my reply as solution. Thank you very much.
If not, please upload some insensitive data samples and expected output.Best Regards,
Community Support Team _ Janey
Hi, Will_Rayner
You don't need to use .date format in code.
I modify your code, Like this:
SLA Target =
MAXX (
FILTER (
ALL ( 'sla' ),
[SLA Code] = SELECTEDVALUE ( 'UW Input for SLA'[SLA Type Name] )
&& [Effective From] <= SELECTEDVALUE ( 'UW Input for SLA'[END_DATE] )
&& [Effective To] >= SELECTEDVALUE ( 'UW Input for SLA'[END_DATE] )
),
[SLA Value]
)
Did I answer your question ? Please mark my reply as solution. Thank you very much.
If not, please upload some insensitive data samples and expected output.
Best Regards,
Community Support Team _ Janey
Yes! That's doing exactly what I need it to. The SLA target values are being selected based on the Type ,and the End Date being within the Efftv from and to dates!
Thank you. Solution accepted!
Will