system.tag.queryTagHistory problem

I am running version 7.3.4 of Ignition and I have the following code setup in my script tester environment:

[code]from java.util import Calendar
from java.util import Date

startDate = Calendar.getInstance()
startDate.set(2012, 9, 1, 0, 0, 0)
startTime = startDate.getTime()

stopDate = Calendar.getInstance()
stopDate.set(2012, 9, 1, 23, 59, 59)
stopTime = stopDate.getTime()

returnSet = system.tag.queryTagHistory([’[history]H2O/Well07/Flow/PV’], startTime, stopTime, 1, “Average”, “Wide”)
print returnSet.getValueAt(1,1)
[/code]

I have run this code several times - with no changes - and only seconds apart. I ran this code last night against a date of 10/1/2012 so there is no new data being logged. Here are my results:
1214, 1223, 1212, 1216, 1220, 1221, 1219, 1214, 1216, 1221, 1215, 1222

Any thoughts on where the variance is coming from? They are all in the same ball park, but it doesn’t make sense that the same calculation against the same set of data would result in different answers.

To make things even stranger, if I modify the code in the following way:

for loop in range(10): returnSet = system.tag.queryTagHistory(['[history]H2O/Well07/Flow/PV'], startTime, stopTime, 1, "Average", "Wide") print returnSet.getValueAt(1,1)

I get exactly the same answer for each iteration in the loop, but each time I run the entire code sample I get a different answer for the loop. The first time I got 1220 for ten iterations. The next time I got 1222 10 for all ten iterations and so on and so forth.

The good news is I was able to reproduce this issue in 7.3.4; bad news is, this fix wasn’t back ported to the 7.3 branch, and was only applied to the 7.5 branch. If you have upgrade protection you’ll want to upgrade, if not you’ll have to talk to your account representative about how to deal with this.

Interesting. So aside from upgrading there is no way to get the function to behave correctly?

I will discuss the upgrade option with our client and see what their status is on the upgrade protection. I believe that I have found a workaround by searching in the forums that will bridge the gap.

Thanks for the response!