# Publish to 2 mqtt topics with only an item

**URL:** <https://community.openhab.org/t/publish-to-2-mqtt-topics-with-only-an-item/68602>\
**Category:** Bindings\
**Tags:** mqtt\
**Created:** [February 23, 2019, 6:59pm UTC](https://community.openhab.org/t/publish-to-2-mqtt-topics-with-only-an-item/68602 "2019-02-23T18:59:04Z")\
**Posts on this page:** 1\
**Showing post:** 9

<div class="post-metadata">

**Author:** ![rlkoshak](https://community.openhab.org/user_avatar/community.openhab.org/rlkoshak/32/75251_2.png) [@rlkoshak](https://community.openhab.org/u/rlkoshak)\
**Post date:** [February 26, 2019, 3:12pm UTC](https://community.openhab.org/t/publish-to-2-mqtt-topics-with-only-an-item/68602/9 "2019-02-26T15:12:59Z")

</div>

Please [How to use code fences](https://community.openhab.org/t/how-to-use-code-fences/38383).

> [@rafa](#):
>
> I would like to program a contact item that is OPEN when it is OPEN from “in/F\_Garage\_Door\_Opened/state” and is CLOSE when it is OPEN from “in/F\_Garage\_Door\_Closed/state”.

There is a bug in the binding right now that makes this not possible using just one Item. You need two separate Items , one for each topic, and a Rule to forward the new states to Garage\_Contact which will become a proxy Item not linked to any Channels.

---

_[View the full topic](https://community.openhab.org/t/publish-to-2-mqtt-topics-with-only-an-item/68602)._
