# Setting Flow variable in Template

**URL:** <https://discourse.nodered.org/t/setting-flow-variable-in-template/18866>\
**Category:** General\
**Created:** [6 December 2019 14:11 UTC](https://discourse.nodered.org/t/setting-flow-variable-in-template/18866 "2019-12-06T14:11:18Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jlb](https://avatars.discourse-cdn.com/v4/letter/j/a9adbd/32.png) [@jlb](https://discourse.nodered.org/u/jlb)\
**Post date:** [6 December 2019 14:11 UTC](https://discourse.nodered.org/t/setting-flow-variable-in-template/18866/1 "2019-12-06T14:11:18Z")

</div>

Hello,

I have searched over the forum but not find a solution:

In a template node I know how to get the value from a flow variable defined in a function node ,for example:

`Amh_orig_X={{flow."origine_X"}}`

works well, but to set a flow variable from a template node ?

The documentation says something like that: `{{flow[store].name}}`

But what value have to be `[store]` ? For example, if i wish to store the value "100" in "MyValue" is it:

`{{flow[100].MyValue}}` ? or `{{flow["100"].MyValue}}` ? What is the good syntax ?

Thanks for your help !

---

<div class="post-metadata">

**Author:** ![bakman2](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/bakman2/32/6207_2.png) [@bakman2](https://discourse.nodered.org/u/bakman2)\
**Post date:** [6 December 2019 14:17 UTC](https://discourse.nodered.org/t/setting-flow-variable-in-template/18866/2 "2019-12-06T14:17:07Z")

</div>

You don't "set" properties in the template node, only read them.  
The template node is used to format messages, not to manipulate them.

---

<div class="post-metadata">

**Author:** ![jlb](https://avatars.discourse-cdn.com/v4/letter/j/a9adbd/32.png) [@jlb](https://discourse.nodered.org/u/jlb)\
**Post date:** [6 December 2019 14:55 UTC](https://discourse.nodered.org/t/setting-flow-variable-in-template/18866/3 "2019-12-06T14:55:39Z")

</div>

😥  
Ok, thanks
