# system.dataset.toDataSet Wrong Number of Columns

**URL:** <https://forum.inductiveautomation.com/t/system-dataset-todataset-wrong-number-of-columns/23510>\
**Category:** Ignition\
**Created:** [March 21, 2019, 3:54pm UTC](https://forum.inductiveautomation.com/t/system-dataset-todataset-wrong-number-of-columns/23510 "2019-03-21T15:54:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dkhayes117](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/dkhayes117/32/68344_2.png) [@dkhayes117](https://forum.inductiveautomation.com/u/dkhayes117)\
**Post date:** [March 21, 2019, 3:54pm UTC](https://forum.inductiveautomation.com/t/system-dataset-todataset-wrong-number-of-columns/23510/1 "2019-03-21T15:54:04Z")

</div>

I’m stumped on why this won’t work. All I want is a dataset with one column and one row, but I get  
`Row 0 doesn't have the same number of columns as header list`

```auto
	header = ['column']
	rows = ['MANHATTAN']
	system.dataset.toDataSet(header,rows)

```

---

<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 21, 2019, 3:56pm UTC](https://forum.inductiveautomation.com/t/system-dataset-todataset-wrong-number-of-columns/23510/2 "2019-03-21T15:56:50Z")

</div>

The second argument to `toDataSet` needs to be a list of lists - one list containing each row, and each row being the actual values. `rows = [['MANHATTAN']]` would work.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [March 21, 2019, 3:58pm UTC](https://forum.inductiveautomation.com/t/system-dataset-todataset-wrong-number-of-columns/23510/3 "2019-03-21T15:58:25Z")

</div>

Your rows variable needs to be list of lists. Since strings can be treated as lists of characters, it sees one row of nine columns containing one character each. Add another set of brackets.
