# Convert dataset column values from string to integer

**URL:** <https://forum.inductiveautomation.com/t/convert-dataset-column-values-from-string-to-integer/10886>\
**Category:** Ignition\
**Created:** [December 8, 2015, 2:08am UTC](https://forum.inductiveautomation.com/t/convert-dataset-column-values-from-string-to-integer/10886 "2015-12-08T02:08:12Z")\
**Posts on this page:** 1\
**Showing post:** 21

<div class="post-metadata">

**Author:** ![witman](https://avatars.discourse-cdn.com/v4/letter/w/d2c977/32.png) [@witman](https://forum.inductiveautomation.com/u/witman)\
**Post date:** [March 2, 2019, 4:12pm UTC](https://forum.inductiveautomation.com/t/convert-dataset-column-values-from-string-to-integer/10886/21 "2019-03-02T16:12:54Z")

</div>

> [@tamerplc](#):
>
> i need to convert string to Datetime what’s the code should be used

[system.date.parse](https://docs.inductiveautomation.com/display/DOC79/system.date.parse). See example in line 13 of code here:

> [@Convert string column to Datetime](http://forum.inductiveautomation.com/t/convert-string-column-to-datetime/23013/2):
>
> You can iterate through the rows of that dataset converting date strings to dates something like this: # Create sample dataset with date strings. headers = ['DateTime', 'Value'] data = [['2019-02-27 22:57:00.0000000',72181]] data.append(['2019-02-28 22:57:00.0000000', 73365]) data.append(['2019-03-01 22:57:00.0000000', 73905]) dataset = system.dataset.toDataSet(headers, data) # Convert date strings in first column to dates in new dataset. newData = [] print 'Original rows:' for row in range(dat…

---

_[View the full topic](https://forum.inductiveautomation.com/t/convert-dataset-column-values-from-string-to-integer/10886)._
