# Script filtering on Power Table

**URL:** <https://forum.inductiveautomation.com/t/script-filtering-on-power-table/23673>\
**Category:** Ignition\
**Created:** [March 27, 2019, 11:49pm UTC](https://forum.inductiveautomation.com/t/script-filtering-on-power-table/23673 "2019-03-27T23:49:19Z")\
**Posts on this page:** 1\
**Showing post:** 2

<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:** [March 27, 2019, 11:59pm UTC](https://forum.inductiveautomation.com/t/script-filtering-on-power-table/23673/2 "2019-03-27T23:59:30Z")

</div>

Knew I had this lying around somewhere:

> [@Programmatically-applied PowerTable Filters](http://forum.inductiveautomation.com/t/programmatically-applied-powertable-filters/15495/2):
>
> model = self.getTable().getModel().getActualModel() from com.jidesoft.grid import SingleValueFilter class newFilter(SingleValueFilter): def isValueFiltered(self, value): return True if value == target.data.getValueAt(row, 4) else False model.addFilter(3, newFilter()) model.setFiltersApplied(True) model.refresh() I’ve used this code before to successfully apply a filter (shows the filter icon in the table header correctly), and it also allows it to be removed by select…

---

_[View the full topic](https://forum.inductiveautomation.com/t/script-filtering-on-power-table/23673)._
