Write multiple PI values to a single row in a timely manner
- Last UpdatedAug 19, 2025
- 1 minute read
- PI System
- Interfaces
The interface can output more than one value to a single database row. To configure it, define an INSERT query that takes snapshot values of various tags. Use the 'tagname'/VL placeholder format. For example, the following query takes snapshot values from three different PI Random Simulator interface tags and inserts them to a table for each scan.
INSERT INTO table1 (timestamp, value1, value2, value3)
VALUES (?,?,?,?);
|
Point Attribute |
Setting |
|---|---|
|
ExDesc |
|
|
Location4 |
1 |
The preceding query writes the following row to a table:
|
Timestamp |
SINUSOID Value1 |
SINUSOIDU Value2 |
CDT158 Value3 |
|---|---|---|---|
|
01-Oct-2015 10:00:00 |
91.23 |
47.81 |
237.9 |
|
01-Oct-2015 10:15:00 |
98.1 |
49.23 |
31.1 |
|
01-Oct-2015 10:30:00 |
99.85 |
50.1 |
137.5 |