# Write to DB with Save Button Script

**URL:** <https://forum.inductiveautomation.com/t/write-to-db-with-save-button-script/81960>\
**Category:** Ignition\
**Created:** [November 15, 2023, 9:38pm UTC](https://forum.inductiveautomation.com/t/write-to-db-with-save-button-script/81960 "2023-11-15T21:38:32Z")\
**Posts on this page:** 1\
**Showing post:** 10

<div class="post-metadata">

**Author:** ![lrose](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/lrose/32/62724_2.png) [@lrose](https://forum.inductiveautomation.com/u/lrose)\
**Post date:** [November 15, 2023, 11:19pm UTC](https://forum.inductiveautomation.com/t/write-to-db-with-save-button-script/81960/10 "2023-11-15T23:19:37Z")

</div>

> [@Transistor](#):
>
> I have a tremendous fund of ignorance to draw from!

I share that trait.

I have this bookmarked:

> [@Event Configuration Print Out to debug](https://forum.inductiveautomation.com/t/event-configuration-print-out-to-debug/60091/5):
>
> It’s complicated slight_smile Starting from most local to least… In the script console, print will log directly to the output buffer on the right hand side. system.util.getLogger() will log to the named ‘Output Console’ Designer window. Bonus: A script invoked from here using system.util.invokeAsync will print to the regular output console, not the buffer on the right hand side. Anywhere else in the designer (except Perspective), print and system.util.getLogger will log to the ‘Out…

Of particular interest is the last part of that. Very helpful, since I almost always have the developer tools open when working in perspective.

> [@Event Configuration Print Out to debug](https://forum.inductiveautomation.com/t/event-configuration-print-out-to-debug/60091/5):
>
> `system.perspective.print` has a ‘scope’ argument. If unspecified or set to ‘client’, output will be sent to the _browser console_ wherever the session is running, and _not logged to the gateway_. If scope is set to ‘gateway’, then output is logged…to the gateway.

---

_[View the full topic](https://forum.inductiveautomation.com/t/write-to-db-with-save-button-script/81960)._
