we are fetching data from PI DA using PI SQL query, but it's showing the time stamp different as per the archive data. Can anyone suggest how to pull the event time stamp value using query.


PISQL.png

PIDA.png

Parents
  • Hi. In OLEDB, you're querying the piinterp table, which yields interpolated values starting at '*' with the given timestep (default: 1h). So the values you get are timestamped xx:09:51 because you ran your query at 09 minutes and 51 seconds after the hour.

    Change your query so you're pulling from the picomp2 table instead, which holds compressed (archived) values instead, and you'll see they'll match the timestamps from SMT

Reply
  • Hi. In OLEDB, you're querying the piinterp table, which yields interpolated values starting at '*' with the given timestep (default: 1h). So the values you get are timestamped xx:09:51 because you ran your query at 09 minutes and 51 seconds after the hour.

    Change your query so you're pulling from the picomp2 table instead, which holds compressed (archived) values instead, and you'll see they'll match the timestamps from SMT

Children