# Vision Power Table - OnCellEdited Scripting Not Refreshing

**URL:** <https://forum.inductiveautomation.com/t/vision-power-table-oncelledited-scripting-not-refreshing/109785>\
**Category:** Ignition\
**Tags:** ignition81, vision, scripting\
**Created:** [August 14, 2025, 6:28pm UTC](https://forum.inductiveautomation.com/t/vision-power-table-oncelledited-scripting-not-refreshing/109785 "2025-08-14T18:28:01Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![McLendon\_Automation](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mclendon_automation/32/78325_2.png) [@McLendon\_Automation](https://forum.inductiveautomation.com/u/McLendon_Automation)\
**Post date:** [August 14, 2025, 6:28pm UTC](https://forum.inductiveautomation.com/t/vision-power-table-oncelledited-scripting-not-refreshing/109785/1 "2025-08-14T18:28:01Z")

</div>

I am trying to run the following Power Table Component Scripting in the onCellEdited Extension Function. Ignition Version 8.1.48, The data is stored in SQL Server 2022. The cells update the SQL Server Table but my Power Table does not refresh. If I set the Polling Mode of the Power Table Data Property (also where my original SQL Query resides) to Relative or Absolute then it will refresh when those timers fire. In the past I have been able to use this exact script with no issues.

Can anyone see where I am messing up?

 ![ocCelledited script_Not Refreshing](https://us1.discourse-cdn.com/inductiveautomation/original/3X/1/1/11493e99414586a8ae29762ed3a8f551837f46d5.png)

---

<div class="post-metadata">

**Author:** ![ryan.white](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan.white/32/73193_2.png) [@ryan.white](https://forum.inductiveautomation.com/u/ryan.white)\
**Post date:** [August 14, 2025, 6:32pm UTC](https://forum.inductiveautomation.com/t/vision-power-table-oncelledited-scripting-not-refreshing/109785/2 "2025-08-14T18:32:00Z")

</div>

You need to provide a reference to the component, and then the name of the property separately:  
`system.db.refresh(self, ‘data’)`

> **[system.db.refresh | Ignition User Manual](https://www.docs.inductiveautomation.com/docs/8.1/appendix/scripting-functions/system-db/system-db-refresh#syntax)**
>
> This function will programmatically cause a SQL Query or DB Browse property binding to execute immediately.

Looks like you might have confused the argument syntax with the perspective equivalent method of `refreshBinding(path.to.component.property)`

> **[Perspective Component Methods | Ignition User Manual](https://www.docs.inductiveautomation.com/docs/8.1/ignition-modules/perspective/scripting-in-perspective/perspective-component-methods#refreshing-bindings)**
>
> A component method is a function that is defined on a component object. For example, this is how we would call a component method defined on the component object self:

---

<div class="post-metadata">

**Author:** ![McLendon\_Automation](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mclendon_automation/32/78325_2.png) [@McLendon\_Automation](https://forum.inductiveautomation.com/u/McLendon_Automation)\
**Post date:** [August 14, 2025, 7:30pm UTC](https://forum.inductiveautomation.com/t/vision-power-table-oncelledited-scripting-not-refreshing/109785/3 "2025-08-14T19:30:34Z")

</div>

> [@ryan.white](#):
>
> system.db.refresh(self, ‘data’)

I created a test Power Table to query a different db table that has test type data stored in it.

The Update Query and the system.db.refresh(self, “data”) appear to function properly.

I went back and tried it on the Power Table that is part of this project and found that the Update query isn’t working properly. Meaning when a cell is edited the table is not updating and the Power Table reverts back to the previous cell data. I’m thinking the Update Query wasn’t working the entire time and I miss-diagnosed the issue as a refresh problem.

Take a look at the query that is populating this Power Table and see if the original query might be the culprit.

 ![Pricing Power Table Query](https://us1.discourse-cdn.com/inductiveautomation/original/3X/8/e/8e95a31c3ec97e2d5214b3946c305257cdff0a11.png)

---

<div class="post-metadata">

**Author:** ![ryan.white](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan.white/32/73193_2.png) [@ryan.white](https://forum.inductiveautomation.com/u/ryan.white)\
**Post date:** [August 14, 2025, 7:37pm UTC](https://forum.inductiveautomation.com/t/vision-power-table-oncelledited-scripting-not-refreshing/109785/4 "2025-08-14T19:37:30Z")

</div>

I’m not seeing you select `ndx` anywhere in that query. Your update statement is probably running but updating something you didn’t intend because you are using the first column value (material in this case) as the value to check for in the `ndx` column.

Add `ndx` to the front of the selection statement that you’ve shown.(Assuming such a column exists in the table)

---

<div class="post-metadata">

**Author:** ![McLendon\_Automation](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mclendon_automation/32/78325_2.png) [@McLendon\_Automation](https://forum.inductiveautomation.com/u/McLendon_Automation)\
**Post date:** [August 14, 2025, 8:20pm UTC](https://forum.inductiveautomation.com/t/vision-power-table-oncelledited-scripting-not-refreshing/109785/5 "2025-08-14T20:20:22Z")

</div>

Thanks again ryan.white, you are saving my bacon. For future reference, I have attached a few pics of the Power Table’s Data Binding, Power Table Scripting, and the Power Table’s Customizer.

This combination appears to be working correctly.

 ![Power Table Data Property SQL Query Binding](https://us1.discourse-cdn.com/inductiveautomation/original/3X/a/0/a0b8f3659b9782e98f01db0567f5cdfe9434c88a.png)

 ![Power Table-_onCelledited - Update Query and Table Refresh Scripting](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/3/33b18586b75d2ed4682ff1d2e2527ded1a3b85f1.png)

 ![Power Table Customizer](https://us1.discourse-cdn.com/inductiveautomation/original/3X/f/e/feb97bbe689948d59d8a0f6913246ddec3da064c.png)
