![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I have data that has been captured in historian. I'm trying to create a view that displays data captured via a Historian in a Pivot Table. I'm having trouble with using the PIVOT operator. Any help on how this could be turned into a pivot table? SELECT DateTime, TagName, Value AS Pressure FROM History WHERE (DateTime >= CONVERT(DATETIME, '2010-12-22 00:00:00', 102)) AND (TagName IN ('Rough', 'HiVac1', 'Leg1', 'Leg2') 'What I get 2010/12/23 Rough 2.100 2010/12/23 HiVac1 1433.59 2010/12/23 Leg1 1536 2010/12/23 Leg2 0.40 2010/12/24 Rough 2.100 2010/12/24 HiVac1 3276.80 2010/12/24 Leg1 3379 2010/12/24 Leg2 2.10 'What I'm trying to get Rough HiVac1 Leg1 Leg2 2010/12/23 2.100 1433.59 1536 0.40 2010/12/24 2.100 3276.80 3379 2.10 Thanks in advance for any help. |
#3
| |||
| |||
|
|
I have data that has been captured in historian. I'm trying to create a view that displays data captured via a Historian in a Pivot Table. I'm having trouble with using the PIVOT operator. Any help on how this could be turned into a pivot table? SELECT DateTime, TagName, Value AS Pressure FROM History WHERE (DateTime >= CONVERT(DATETIME, '2010-12-22 00:00:00', 102)) AND (TagName IN ('Rough', 'HiVac1', 'Leg1', 'Leg2') ... 'What I'm trying to get Rough HiVac1 Leg1 Leg2 2010/12/23 2.100 1433.59 1536 0.40 2010/12/24 2.100 3276.80 3379 2.10 |
![]() |
| Thread Tools | |
| Display Modes | |
| |