# Rename the column of a dataset

**URL:** <https://forum.inductiveautomation.com/t/rename-the-column-of-a-dataset/56043>\
**Category:** Ignition\
**Created:** [February 11, 2022, 5:34pm UTC](https://forum.inductiveautomation.com/t/rename-the-column-of-a-dataset/56043 "2022-02-11T17:34:32Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![lrose](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/lrose/32/62724_2.png) [@lrose](https://forum.inductiveautomation.com/u/lrose)\
**Post date:** [February 11, 2022, 5:52pm UTC](https://forum.inductiveautomation.com/t/rename-the-column-of-a-dataset/56043/2 "2022-02-11T17:52:59Z")

</div>

Depends on where the dataset is coming from. The easiest way is to change it at the source.

If you really want to do this in script then you would have to rebuild the Dataset

```auto
ds = *Your Data*
headers = system.dataset.getColumnHeaders()
headers[3] = "New Column Name"
values = [[ds.getValueAt(row,col) for col in range(ds.columnCount)] for row in range(ds.rowCount)]
ds = system.dataset.toDataSet(headers,values)

```

---

_[View the full topic](https://forum.inductiveautomation.com/t/rename-the-column-of-a-dataset/56043)._
