system.historian.queryRawPoints
This function is used in Python Scripting.
Description​
Queries raw data points for the specified historian.
Client Permission Restrictions​
This scripting function has no Client Permission restrictions.
Syntax​
system.historian.queryRawPoints(paths, startTime, endTime, [columnNames], [returnFormat], [returnSize], includeBounds, [excludeObservations])
Parameters​
Type | Parameter | Description |
---|---|---|
List | paths | A list of historical paths to query aggregated data points for. |
Date | startTime | A start time to query aggregated data points for. |
Date | endTime | An end time to query aggregated data points for. |
List | columnNames | A list of alias column names for the returned dataset. [Optional] |
String | returnFormat | The desired return format for the query. [Optional] |
Integer | returnSize | The maximum number of results to return. [Optional] |
Boolean | includeBounds | Whether to include the bounds in the query results. |
Boolean | excludeObservations | Whether to exclude observed aggregated data points in the query results. [Optional] |
Returns​
Dataset - A dataset representing the raw data points for the specified historical paths.
Scope​
Gateway, Vision Client, Perspective Session
Code Examples​
Code Snippet
# Query a specified historical simulator tag path and display raw data from within the past minute
end = system.date.now()
start = system.date.addMinutes(end, -1)
myDataset = system.historian.queryRawPoints(["[default]_Simulator_/Random/RandomInteger1"], start, end, includeBounds=False)
for row in myDataset:
print row[0], row[1]