# Perspective property binding with expression transform behaves differently than equivalent expression

**URL:** <https://forum.inductiveautomation.com/t/perspective-property-binding-with-expression-transform-behaves-differently-than-equivalent-expression/39382>\
**Category:** Ignition\
**Created:** [October 5, 2020, 5:39pm UTC](https://forum.inductiveautomation.com/t/perspective-property-binding-with-expression-transform-behaves-differently-than-equivalent-expression/39382 "2020-10-05T17:39:14Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![weertske](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/weertske/32/3353_2.png) [@weertske](https://forum.inductiveautomation.com/u/weertske)\
**Post date:** [October 5, 2020, 5:39pm UTC](https://forum.inductiveautomation.com/t/perspective-property-binding-with-expression-transform-behaves-differently-than-equivalent-expression/39382/1 "2020-10-05T17:39:14Z")

</div>

This binding:

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/7/a/7a697b6ee0428ce7f0312fd4d9b0ea09af516b15.png)

Behaves differently from this binding:

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/5/a/5a472a0c6010e9ba63ab3ea5be7f7fbd026e842b.png)

They should behave identically. However when I try to lookup data from the resulting dataset of the first binding the result is not consistent (it keeps changing).

Any ideas?

---

<div class="post-metadata">

**Author:** ![Matthew.gaitan](https://avatars.discourse-cdn.com/v4/letter/m/59ef9b/32.png) [@Matthew.gaitan](https://forum.inductiveautomation.com/u/Matthew.gaitan)\
**Post date:** [October 5, 2020, 9:11pm UTC](https://forum.inductiveautomation.com/t/perspective-property-binding-with-expression-transform-behaves-differently-than-equivalent-expression/39382/2 "2020-10-05T21:11:26Z")

</div>

My guess is that the top way you’re only subscribing to changes on the property `this.custom.recipeBuilder`. I believe that value has to change before the following expression is evaluated.

With the second image, any of the changes will cause the event to fire.

---

<div class="post-metadata">

**Author:** ![weertske](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/weertske/32/3353_2.png) [@weertske](https://forum.inductiveautomation.com/u/weertske)\
**Post date:** [October 6, 2020, 12:43am UTC](https://forum.inductiveautomation.com/t/perspective-property-binding-with-expression-transform-behaves-differently-than-equivalent-expression/39382/3 "2020-10-06T00:43:32Z")

</div>

I don’t believe so. The recipe builder property is the result of a SQL binding that only runs once.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [October 6, 2020, 12:29pm UTC](https://forum.inductiveautomation.com/t/perspective-property-binding-with-expression-transform-behaves-differently-than-equivalent-expression/39382/4 "2020-10-06T12:29:36Z")

</div>

Try testing with a simpler expression, say with just the property value and one other property. No indirection. Change one then the other to see what happens. Add more complexity a bit at a time until you understand what is happening. And for pity’s sake, don’t add back any tag() functions.

---

<div class="post-metadata">

**Author:** ![kgamble](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kgamble/32/8019_2.png) [@kgamble](https://forum.inductiveautomation.com/u/kgamble)\
**Post date:** [October 6, 2020, 2:02pm UTC](https://forum.inductiveautomation.com/t/perspective-property-binding-with-expression-transform-behaves-differently-than-equivalent-expression/39382/5 "2020-10-06T14:02:35Z")

</div>

In doing what Phil says, I would actually break this sort into three different bindings

Two indirect tag bindings, then use `if(isGood(tag1), tag1, tag2)` for the part checking quality against your new tag binding

---

<div class="post-metadata">

**Author:** ![weertske](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/weertske/32/3353_2.png) [@weertske](https://forum.inductiveautomation.com/u/weertske)\
**Post date:** [October 6, 2020, 3:05pm UTC](https://forum.inductiveautomation.com/t/perspective-property-binding-with-expression-transform-behaves-differently-than-equivalent-expression/39382/6 "2020-10-06T15:05:13Z")

</div>

Phil, I knew you were going to say that about the tag() function. 😉 However due to the complex nature of the binding, I couldn’t use indirect tags unless I do what Keith is saying. I hadn’t thought of that approach and will examine that as an alternative.

Still, I am curious why two functionally identical binding don’t behave the same.

---

<div class="post-metadata">

**Author:** ![kgamble](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kgamble/32/8019_2.png) [@kgamble](https://forum.inductiveautomation.com/u/kgamble)\
**Post date:** [October 6, 2020, 5:32pm UTC](https://forum.inductiveautomation.com/t/perspective-property-binding-with-expression-transform-behaves-differently-than-equivalent-expression/39382/7 "2020-10-06T17:32:13Z")

</div>

> [@weertske](#):
>
> Still, I am curious why two functionally identical binding don’t behave the same.

Could be that when you do it all in the expression it works no problem, but when you do it as a transform it’s treating `{value}` as an ObjectWrapper object instead of a string?
