Hey @Fouad
It is not working because you are referring to the wrong field. Which action is returnign the yes/no type field?
I tested with a get items action and in the apply to each I am sending some stuff so based on that the expression is:
if(empty(string(items('Apply_to_each')?['TaskStatus'])),null,if(equals(items('Apply_to_each')?['TaskStatus'],true),'Yes','No'))
Here, taskstatus is the column name and is of type yes/no and the apply to each is iterating over each item from the get items.
if you are doing it on the get item action, replace the reference to the field accordingly.
Hope this Helps!
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!