# Openhab Presence monitoring

**URL:** <https://discourse.nodered.org/t/openhab-presence-monitoring/6053>\
**Category:** General\
**Created:** [22 December 2018 01:18 UTC](https://discourse.nodered.org/t/openhab-presence-monitoring/6053 "2018-12-22T01:18:35Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![ukmoose](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ukmoose/32/13_2.png) [@ukmoose](https://discourse.nodered.org/u/ukmoose)\
**Post date:** [22 December 2018 01:37 UTC](https://discourse.nodered.org/t/openhab-presence-monitoring/6053/2 "2018-12-22T01:37:27Z")

</div>

Assuming all the information is held within the same message, you could do it with a switch node followed by a switch node. Or by using a function node with a javascript if this AND that type statement (google for the correct syntax)

If the information isn’t within the same message you need to get it there, you could use a join node, or store the data in memory. This has come up a lot in the past couple of days. There’s and example here [Output two attributes in the template](https://discourse.nodered.org/t/output-two-attributes-in-the-template/5983/6)  
and you can read the docs within the working with function part of the documentation

---

_[View the full topic](https://discourse.nodered.org/t/openhab-presence-monitoring/6053)._
