# Tag History and Tables

**URL:** <https://forum.inductiveautomation.com/t/tag-history-and-tables/76707>\
**Category:** Ignition\
**Tags:** scripting\
**Created:** [July 21, 2023, 2:38pm UTC](https://forum.inductiveautomation.com/t/tag-history-and-tables/76707 "2023-07-21T14:38:36Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![MSI\_EXP\_Auto](https://avatars.discourse-cdn.com/v4/letter/m/fbc32d/32.png) [@MSI\_EXP\_Auto](https://forum.inductiveautomation.com/u/MSI_EXP_Auto)\
**Post date:** [July 21, 2023, 2:38pm UTC](https://forum.inductiveautomation.com/t/tag-history-and-tables/76707/1 "2023-07-21T14:38:36Z")

</div>

I am trying to create a simple table from tag historian with a few tags to just look at temperature data. All tags are set to periodic sampling every minute, right now I am seeing this -

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/5/2/52eecac5050716e3f247809acc5714251b099f0f.png)  
Where ideally I'd only see one row per minute. Right now I have data linked to tag history where I'm pulling it as stored for a specific time range and then applying this script to remove duplicate rows.

```auto
oldDataset = value
headers = system.dataset.getColumnHeaders(oldDataset)*
# convert to pyDataset, so the data is compatible with the set constructor
pyData = system.dataset.toPyDataSet(oldDataset)
# turn the lists into tuples so they are hashable
tuples = map(tuple, pyData)
# create a set from the list of tuples 
pySet = set(tuples)
#convert set back into a list
newData = list(pySet)
#create an Ignition dataset from the headers and data without duplicates
newDataset = system.dataset.toDataSet(headers, newData)
return newDataset

```

I think the timestamps are causing the issues but when I look into the historian I see all tags I'm interested in are logged at the same time -

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/a/0/a0d4f9b530130a9768360ddbd33fa44e550dbfdc.png)

Any ideas to get what I am looking for? Or what is the cause of the duplicate rows?
