Data received from ThingTemplates
Hello. I've an issue and I was wondering if anyone can help me.
I'm currently trying to fetch property history for Things that I've simulated in my local Thingworx composer through the API using the ThingTemplates/Services/QueryImplementingThingsWithPropertyHistory and my goal is to get only the latest entry for each Thing that I've. I thought I could achieve this using the MaxDataItems=1 but I'm getting something like this:
"rows": [
{
"Temperature": 68,
"name": "CD 001",
"Gyroscope": 0,
"CustomerName": "Something",
"Cash": 45,
"Pressure": 20,
"Stock": 71,
"timestamp": 1482420116565
},
{
"Temperature": 68,
"name": "CD 001",
"CustomerName": "Something",
"Cash": 45,
"Pressure": 20,
"Stock": 71,
"timestamp": 1482420116564
},
{
"name": "CD 001",
"Cash": 45,
"Pressure": 20,
"Stock": 71,
"timestamp": 1482420116561
},
{
"name": "CD 001",
"Cash": 45,
"Stock": 71,
"timestamp": 1482417836498
},
{
"name": "CD 001",
"Cash": 45,
"timestamp": 1482417836497
},
...
]
As you can see I'm getting several rows for the same device with name "CD 001". Can anyone tell me if there is a better way to fetch just the first entry (which is the most complete one as well as the most recent) or is this behavior happening just because I'm simulating data on the same timer?
Thank you for your time and help in advance

