Can you please share a pbix file for test? It is hard to test on your formula without detail sample data. Notice: Do mask on sensitive before share. If you not have permission to update file, you can upload them to onedrive or google drive and share link here.
Community Support Team _ Xiaoxin Sheng If this post helps, please consider Accept it as the solution to help the other members find it more quickly Learning resources: Power BI