# Update to database from frontend gateway to backend gateway

**URL:** <https://forum.inductiveautomation.com/t/update-to-database-from-frontend-gateway-to-backend-gateway/111926>\
**Category:** Ignition\
**Tags:** perspective\
**Created:** [November 4, 2025, 1:25pm UTC](https://forum.inductiveautomation.com/t/update-to-database-from-frontend-gateway-to-backend-gateway/111926 "2025-11-04T13:25:23Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Thomas\_Tornblom](https://avatars.discourse-cdn.com/v4/letter/t/c67d28/32.png) [@Thomas\_Tornblom](https://forum.inductiveautomation.com/u/Thomas_Tornblom)\
**Post date:** [November 4, 2025, 1:25pm UTC](https://forum.inductiveautomation.com/t/update-to-database-from-frontend-gateway-to-backend-gateway/111926/1 "2025-11-04T13:25:24Z")

</div>

Si I have followed the seup of a frontend and a backend gateway in docker in the elevated studies in inductive university. So I have two functioning gateways, a database connected to the backend and a smtp setup and working with a working gateway network outgoing from backend to frontend.

I have now set up a project on the frontend in perspective and it’s working fine but I have a button where I want to do an update/insert in the database and since the database is connected to the backend i have created an event script to do this onActionPreformed and the script uses a system.util.sendRequest to send a request to the backend-gateway.  
On the backend gateway I have set up Gateway event script message handler that triggers a Named Query that do the update in the database. The Named Query is thested and works but the problem is on the frontend-gateway that the press of the button fiers the event script but the log on frontend says that “DispatchManager

04Nov2025 14:04:33

Error during message dispatch: Project 'XXX\_backend' was not found!” (I have changed the project namen in this error but the real project name is correct with the project on the backend gateway.

I don’t know what more to do, I have tested and I can’t get it to work. Is there something missing on the backend gateway project? It only handles the gateway event and the named query at the moment this is all the project on the backend contains.

---

<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:** [November 4, 2025, 1:26pm UTC](https://forum.inductiveautomation.com/t/update-to-database-from-frontend-gateway-to-backend-gateway/111926/2 "2025-11-04T13:26:30Z")

</div>

Show your script.

---

<div class="post-metadata">

**Author:** ![Thomas\_Tornblom](https://avatars.discourse-cdn.com/v4/letter/t/c67d28/32.png) [@Thomas\_Tornblom](https://forum.inductiveautomation.com/u/Thomas_Tornblom)\
**Post date:** [November 4, 2025, 1:30pm UTC](https://forum.inductiveautomation.com/t/update-to-database-from-frontend-gateway-to-backend-gateway/111926/3 "2025-11-04T13:30:03Z")

</div>

Okay, here is the part of the script that’s going to send the event to the backend gateway.

```
    resp = system.util.sendRequest(
        project = "Kutter_backend",           
        messageHandler = "InsertBlockData",
        payload = {
            "batchId": batchNumber,
            "orderId": "1234",
            "status": 1,
            "quality": quality
    },
    gateway = "backend-gateway"       
    )

```

---

<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:** [November 4, 2025, 1:40pm UTC](https://forum.inductiveautomation.com/t/update-to-database-from-frontend-gateway-to-backend-gateway/111926/4 "2025-11-04T13:40:04Z")

</div>

The argument `gateway =` should be `remoteServer =`. Check the docs.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [November 4, 2025, 7:27pm UTC](https://forum.inductiveautomation.com/t/update-to-database-from-frontend-gateway-to-backend-gateway/111926/5 "2025-11-04T19:27:26Z")

</div>

![Screenshot 2025-11-04 at 11.26.45 AM](https://us1.discourse-cdn.com/inductiveautomation/original/3X/f/4/f447c11ace035ed54baa7862c9544827078b7fe4.jpeg)

> [@Automatically selecting a role in User Management](https://forum.inductiveautomation.com/t/automatically-selecting-a-role-in-user-management/111830/2):
>
> I'm going to go with a hunch here and say as a preemptive word of advice - don't trust LLMs for help with Ignition scripting, because they lack sufficient context to be helpful.  
> You'll get, at best, way too much code (because they really like to write code) that _might_ accomplish your immediate goal but is going to lead you to problems down the line, and at worst _outright hallucinations_ that make you spin your wheels wasting your time.
