# \[IGN-7140\] Perspective Table - add \`props.selection.selectedRows\`

**URL:** <https://forum.inductiveautomation.com/t/ign-7140-perspective-table-add-props-selection-selectedrows/69378>\
**Category:** Ignition\
**Tags:** perspective\
**Created:** [February 3, 2023, 1:19am UTC](https://forum.inductiveautomation.com/t/ign-7140-perspective-table-add-props-selection-selectedrows/69378 "2023-02-03T01:19:13Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![cmallonee](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cmallonee/32/6416_2.png) [@cmallonee](https://forum.inductiveautomation.com/u/cmallonee)\
**Post date:** [March 13, 2024, 8:28pm UTC](https://forum.inductiveautomation.com/t/ign-7140-perspective-table-add-props-selection-selectedrows/69378/7 "2024-03-13T20:28:46Z")

</div>

While it's true the Table has `props.selectionData`, the objects in that list contain only the data of the row, with no insight into the index of the row in the dataset/list.

Consider the following `data` value, where an object seems to be repeated:

```auto
[
    {"name": "A", "value": 1},
    {"name": "B", "value": 2},
    {"name": "C", "value": 3},
    {"name": "A", "value": 1}
]

```

If a user selects the last row of the data, how are you to know if `props.selectionData` represents the first or last row of data? Due to the complete dataset containing no guaranteed unique value, there is no way to perform something like an update query based on the provided data. FOr Perspective to expose which row is truly selected, we would need to inject some sort of `index` property, which would reflect the 0-based index of the row each entry in `props.selectionData` represents.

Now, here's the problem: what if users have prepared their data with an `index` key which actually means something to them?

```auto
# select * from MyTable where index<30;
[
    {"index": 1, "name": "A", "value": 1},
    {"index": 15, "name": "B", "value": 2},
    {"index": 20, "name": "C", "value": 3},
    {"index": 21, "name": "A", "value": 1}
]

```

If a user clicks the last row again, we can't run the risk of replacing `21` with `3`.

---

_[View the full topic](https://forum.inductiveautomation.com/t/ign-7140-perspective-table-add-props-selection-selectedrows/69378)._
