# How can I get the count of a PyDataSet

**URL:** <https://forum.inductiveautomation.com/t/how-can-i-get-the-count-of-a-pydataset/12673>\
**Category:** Ignition\
**Created:** [February 12, 2017, 6:05am UTC](https://forum.inductiveautomation.com/t/how-can-i-get-the-count-of-a-pydataset/12673 "2017-02-12T06:05:44Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bfaivre](https://avatars.discourse-cdn.com/v4/letter/b/f19dbf/32.png) [@bfaivre](https://forum.inductiveautomation.com/u/bfaivre)\
**Post date:** [February 12, 2017, 6:05am UTC](https://forum.inductiveautomation.com/t/how-can-i-get-the-count-of-a-pydataset/12673/1 "2017-02-12T06:05:44Z")

</div>

Hi,

Looking to get the count of a PyDataSet. Does anyone know how to do this?

Thanks!

Brian

---

<div class="post-metadata">

**Author:** ![diat150](https://avatars.discourse-cdn.com/v4/letter/d/a587f6/32.png) [@diat150](https://forum.inductiveautomation.com/u/diat150)\
**Post date:** [February 12, 2017, 3:38pm UTC](https://forum.inductiveautomation.com/t/how-can-i-get-the-count-of-a-pydataset/12673/2 "2017-02-12T15:38:22Z")

</div>

what do you mean by count? number of rows?

```auto
table = event.source.parent.getComponent("Table")
data = system.dataset.toPyDataSet(table.data)
print len(data)

```

---

<div class="post-metadata">

**Author:** ![bfaivre](https://avatars.discourse-cdn.com/v4/letter/b/f19dbf/32.png) [@bfaivre](https://forum.inductiveautomation.com/u/bfaivre)\
**Post date:** [February 12, 2017, 4:12pm UTC](https://forum.inductiveautomation.com/t/how-can-i-get-the-count-of-a-pydataset/12673/3 "2017-02-12T16:12:49Z")

</div>

Yes - number of rows. Thanks!
