Overcome Uncertain Initial Value quality of expression tag

I have an expression tag and sometimes the quality of this tag becomes 'Uncertain Initial Value'.
Expression:if (!{[.]LossFlag},coalesce({[.]TotLoss},0),coalesce({[.]PrevLoss}, 0)) * toInt(!{[.]ShiftChangeCheck})

Quality becomes good only when i restart the tag.

Any suggestions to overcome this?

I seem to remember this...
I also remember that Phil provided a more robust solution:

I warned you that this was only a little experiment I was doing for fun.

Yes I do remember.
I tried the same. but since I wish to display in live mode, i went with the expression pov.
I am facing the similar error sometimes in other tags too at situations like db restart/gateway restart.
So is there any way to handle this?

I'm guessing this happens because the expression is referencing tags that don't yet have reliable values.
So either change the expression to handle this case, or make a change to the referenced tags to avoid unreliable values.

We'll need more details about those tags to help you more accurately.