I found a problem where different times are displayed in the comments panel and when getting the same data out of the database with a query. Looking at different examples the date can be anywhere from 5 minutes to a half hour difference. Here is a screen shot of what I’m seeing:
Notice that the time in the comments panel is 20 minutes later than the last note added time at the top. These two times come from the same table but the last note added time is received with the following script:
if event.propertyName == "NoteFilter":
search = event.source.NoteFilter
tstamp = system.db.runPrepQuery("SELECT top 1 TimeStamp FROM notes WHERE TagName = ? ORDER BY TimeStamp desc", [search], "IgnitionDB")
date = system.db.dateFormat(tstamp, "MMM d, yyyy hh:MM a")
event.source.text = "Last Note Added: " + date
event.source.text = "No Notes Found"
Did I do something wrong or is this an actual problem? The time difference is not always the same offset, it can vary by (so far) up to a half hour difference.